[PR #4214] [client] Remove custom method from generated proto and use inline logic for connection type filtering #4141

Open
opened 2025-11-20 08:07:48 -05:00 by saavagebueno · 0 comments
Owner

Original Pull Request: https://github.com/netbirdio/netbird/pull/4214

State: closed
Merged: Yes


This PR removes the previously added GetConnectionType() method from the generated PeerState struct, which was an unintended change to generated code. The logic has been moved inline in the status command instead.

Changes:

  • Replaces peerState.GetConnectionType() with direct field access (peerState.Relayed) to determine connection type.
  • Updates skipDetailByFilters() to accept connType as an argument.
  • Avoids modifying generated .pb.go files, preserving proper protobuf generation workflow.
**Original Pull Request:** https://github.com/netbirdio/netbird/pull/4214 **State:** closed **Merged:** Yes --- This PR removes the previously added GetConnectionType() method from the generated PeerState struct, which was an unintended change to generated code. The logic has been moved inline in the status command instead. ### Changes: - Replaces `peerState.GetConnectionType()` with direct field access (`peerState.Relayed`) to determine connection type. - Updates `skipDetailByFilters()` to accept `connType` as an argument. - Avoids modifying generated `.pb.go` files, preserving proper protobuf generation workflow.
saavagebueno added the pull-request label 2025-11-20 08:07:48 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: SVI/netbird#4141