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(circuit-relay): respect applyDefaultLimit when it is false #2139

Merged
merged 2 commits into from
Oct 9, 2023

Conversation

achingbrain
Copy link
Member

@achingbrain achingbrain commented Oct 7, 2023

Description

We were accidentally applying the default limits if no limits were set, which is intentionally the case when the applyDefaultLimit config option is set to false.

Also simplifies the relay test setup to create nodes with just config overrides to remove a bit of the copy/paste.

Change checklist

  • I have performed a self-review of my own code
  • I have made corresponding changes to the documentation if necessary (this includes comments as well)
  • I have added tests that prove my fix is effective or that my feature works

We were accidentally applying the default limits if no limits were
set, which is intentionally the case when the `applyDefaultLimit`
config option is set to `false`.
@achingbrain achingbrain requested a review from a team as a code owner October 7, 2023 08:30
Copy link
Member

@maschad maschad left a comment

Choose a reason for hiding this comment

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

Good catch, I think we can do some refactors and then land it.

packages/libp2p/src/circuit-relay/utils.ts Show resolved Hide resolved
packages/libp2p/src/circuit-relay/utils.ts Show resolved Hide resolved
@achingbrain achingbrain merged commit df2153e into master Oct 9, 2023
17 checks passed
@achingbrain achingbrain deleted the fix/do-not-apply-default-limits branch October 9, 2023 16:42
This was referenced Jan 18, 2024
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