Skip to content

Commit

Permalink
Enforce a lowercase prefix on decoded cashaddresses
Browse files Browse the repository at this point in the history
  • Loading branch information
hanchon authored and schancel committed Jan 13, 2018
1 parent 5f29a00 commit 0c4de11
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cashaddress/decode.go
Expand Up @@ -42,7 +42,7 @@ func Decode(addr string, defaultPrefix string) (*Address, error) {
}

// Unpack the address without the checksum bits
raw, err := unpackAddress(decoded[:len(decoded)-8], prefix)
raw, err := unpackAddress(decoded[:len(decoded)-8], strings.ToLower(prefix))
return raw, err
}

Expand Down

2 comments on commit 0c4de11

@Farshidkhani
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Farshidkhani
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.