Skip to content

Fix alphabets with space in them#78

Merged
junderw merged 1 commit intomasterfrom
fix/space-alphabets
Oct 22, 2021
Merged

Fix alphabets with space in them#78
junderw merged 1 commit intomasterfrom
fix/space-alphabets

Conversation

@junderw
Copy link
Copy Markdown
Member

@junderw junderw commented Oct 21, 2021

Fixes #77

To be released in patch.

Comment thread test/fixtures.json
Comment on lines +606 to +609
"alphabet": "base45",
"hex": "05e9b0213ba6e5e9fc62aa2906",
"string": " /+F5SZ6LLW+ "
},
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

If I understood correctly, hex is (the hexadecimal of) the message to be encoded, and string is the encoded message?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Yes. So encode(Buffer.from(hex, "hex")) should output string and decode(string) should output the same Buffer as Buffer.from(hex, "hex")

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Right, then everything LGTM! I also tried the one message we had failing and it worked, as expected. Thanks for taking care of it so quickly!

@junderw junderw merged commit c9dcddd into master Oct 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Versions 3.0.5 and above are not backwards compatible

2 participants