chore(config): use openvpn protocol string field instead of TCP bool
This commit is contained in:
@@ -4,6 +4,7 @@ import (
|
||||
"fmt"
|
||||
|
||||
"github.com/qdm12/gluetun/internal/configuration/settings"
|
||||
"github.com/qdm12/gluetun/internal/constants"
|
||||
"github.com/qdm12/gluetun/internal/constants/vpn"
|
||||
)
|
||||
|
||||
@@ -22,7 +23,7 @@ func getPort(selection settings.ServerSelection,
|
||||
if customPort > 0 {
|
||||
return customPort
|
||||
}
|
||||
if *selection.OpenVPN.TCP {
|
||||
if selection.OpenVPN.Protocol == constants.TCP {
|
||||
checkDefined("OpenVPN TCP", defaultOpenVPNTCP)
|
||||
return defaultOpenVPNTCP
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user