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

core/src/connection: Add ConnectedPoint::is_relayed #2392

Merged
merged 1 commit into from
Dec 19, 2021

Conversation

mxinden
Copy link
Member

@mxinden mxinden commented Dec 17, 2021

Add convenience function is_relayed to ConnectedPoint, determining
whether a connection is relayed based on whether it contains a
Protocol::P2pCircuit.

//CC @elenaf9 would make suggestion for #2059 (comment) a bit cleaner.

Add convenience function `is_relayed` to `ConnectedPoint`, determining
whether a connection is relayed based on whether it contains a
`Protocol::P2pCircuit`.
Copy link
Contributor

@thomaseizinger thomaseizinger left a comment

Choose a reason for hiding this comment

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

Nice!

I am a fan of enriching the core data structures with functionality like this.

@mxinden mxinden merged commit 176636f into libp2p:master Dec 19, 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.

None yet

3 participants