Skip to content

Commit

Permalink
read, write: use an implicit prefix
Browse files Browse the repository at this point in the history
  • Loading branch information
tuxcanfly committed Mar 3, 2023
1 parent ecae5cb commit 1d8589a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion relayer.go
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@ func (r Relayer) Read(height uint64) ([][]byte, error) {
if start > 0 && len(witness) > start+35 {
end := len(witness) - 35
if end > start {
data = append(data, witness[start:end])
data = append(data, witness[start+4:end])
}
}
}
Expand All @@ -317,6 +317,7 @@ func (r Relayer) Read(height uint64) ([][]byte, error) {
}

func (r Relayer) Write(data []byte) (*chainhash.Hash, error) {
data = append(PROTOCOL_ID, data...)
address, err := createTaprootAddress(data)
if err != nil {
return nil, err
Expand Down

0 comments on commit 1d8589a

Please sign in to comment.