Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix parsed is null error #1535

Merged
merged 4 commits into from
Apr 9, 2020
Merged

Fix parsed is null error #1535

merged 4 commits into from
Apr 9, 2020

Conversation

tomaka
Copy link
Member

@tomaka tomaka commented Mar 31, 2020

cc @expenses

This JS code hasn't really been properly reviewed by anyone unfortunately, and jumped a bit suddenly from "quickly written code to prototype" to "thing that we expect to be robust".

One consequence is that for some reason we checked parsed != null only after using parsed.

Copy link
Member

@mxinden mxinden left a comment

Choose a reason for hiding this comment

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

For what my review on JS code is worth, this looks good to me.

thing that we expect to be robust

Why reinvent the wheel instead of using https://github.com/multiformats/js-multiaddr ? It would introduce some kind of dependency management though.

@tomaka
Copy link
Member Author

tomaka commented Apr 6, 2020

Why reinvent the wheel instead of using https://github.com/multiformats/js-multiaddr ?

Note that we're supporting the x-parity-ws and x-parity-wss protocols (extensions so that one can add a URL to WebSocket addresses, while the exact format is being debated upstream), which aren't a thing in js-multiaddr.

@tomaka tomaka merged commit 8adf474 into libp2p:master Apr 9, 2020
@tomaka tomaka deleted the fix-wasm-ws branch April 9, 2020 13:37
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.

2 participants