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

docs: update pubsub message filtering example to listen for correct event #1360

Closed
wants to merge 1 commit into from

Conversation

inverted-capital
Copy link

@inverted-capital inverted-capital commented Aug 18, 2022

The correct event to listen for is 'message' and the topic name can be discerned from the passed event object.

Fixes #1288

@achingbrain achingbrain changed the title closes #libp2p/js-libp2p/issues/1288 docs: update pubsub message filtering example to listen for correct event Aug 26, 2022
@achingbrain
Copy link
Member

achingbrain commented Aug 26, 2022

Thanks for opening this. I think it needs a bit more of an in-depth fix as although it is run during CI, the test as written doesn't actually test that the message were received. If it did then this regression would have been caught.

I have opened #1362 which refactors the test to actually test something, the example to make the test pass and the README to use the new API.

@inverted-capital
Copy link
Author

Ok thanks - #1362 is a much more thorough fix

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.

bug report: examples/pubsub/message-filtering/1.js
2 participants