Skip to content

Commit

Permalink
fix: use internal method
Browse files Browse the repository at this point in the history
Signed-off-by: hlts2 <[email protected]>
  • Loading branch information
hlts2 committed Dec 5, 2023
1 parent 2b1cac5 commit 19ee272
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/gateway/mirror/service/mirror.go
Original file line number Diff line number Diff line change
Expand Up @@ -287,7 +287,7 @@ func (m *mirr) Disconnect(ctx context.Context, targets ...*payload.Mirror_Target
}
for _, target := range targets {
addr := net.JoinHostPort(target.GetHost(), uint16(target.GetPort()))
if _, ok := m.gwAddrl.Load(addr); !ok {
if !m.isGatewayAddr(addr) {
_, ok := m.addrl.Load(addr)
if ok || m.IsConnected(ctx, addr) {
if err := m.gateway.GRPCClient().Disconnect(ctx, addr); err != nil &&
Expand Down

0 comments on commit 19ee272

Please sign in to comment.