diff options
| -rw-r--r-- | internal/api/api_test.go | 2 | ||||
| -rw-r--r-- | internal/api/profiles/profiles.go | 2 | ||||
| -rw-r--r-- | proxy/proxy.go | 6 |
3 files changed, 5 insertions, 5 deletions
diff --git a/internal/api/api_test.go b/internal/api/api_test.go index 5034465..2170743 100644 --- a/internal/api/api_test.go +++ b/internal/api/api_test.go @@ -292,7 +292,7 @@ func TestAPIInfo(t *testing.T) { ID: "test1", DisplayName: "test profile 1", VPNProtoList: []string{"openvpn", "wireguard"}, - Priority: 3, + Priority: 3, DefaultGateway: false, }, }, diff --git a/internal/api/profiles/profiles.go b/internal/api/profiles/profiles.go index e835ffe..77109f1 100644 --- a/internal/api/profiles/profiles.go +++ b/internal/api/profiles/profiles.go @@ -112,7 +112,7 @@ func (i Info) Public() server.Profiles { "en": p.DisplayName, }, DefaultGateway: p.DefaultGateway, - Priority: p.Priority, + Priority: p.Priority, } } return server.Profiles{Map: m} diff --git a/proxy/proxy.go b/proxy/proxy.go index e0dba4f..34c281f 100644 --- a/proxy/proxy.go +++ b/proxy/proxy.go @@ -66,12 +66,12 @@ func (p *Proxy) Tunnel(ctx context.Context, wglisten int) error { }() select { - case err := <- errChan: + case err := <-errChan: cancel() return err - case <- p.resChan: + case <-p.resChan: cancel() - <- errChan + <-errChan return p.Tunnel(ctx, wglisten) } } |
