diff --git a/internal/configuration/settings/serverselection.go b/internal/configuration/settings/serverselection.go index ee78949f..175cf29c 100644 --- a/internal/configuration/settings/serverselection.go +++ b/internal/configuration/settings/serverselection.go @@ -274,7 +274,7 @@ func (ss *ServerSelection) mergeWith(other ServerSelection) { ss.Cities = helpers.MergeStringSlices(ss.Cities, other.Cities) ss.ISPs = helpers.MergeStringSlices(ss.ISPs, other.ISPs) ss.Hostnames = helpers.MergeStringSlices(ss.Hostnames, other.Hostnames) - ss.Names = helpers.MergeStringSlices(ss.Hostnames, other.Names) + ss.Names = helpers.MergeStringSlices(ss.Names, other.Names) ss.Numbers = helpers.MergeUint16Slices(ss.Numbers, other.Numbers) ss.OwnedOnly = helpers.MergeWithBool(ss.OwnedOnly, other.OwnedOnly) ss.FreeOnly = helpers.MergeWithBool(ss.FreeOnly, other.FreeOnly) @@ -293,7 +293,7 @@ func (ss *ServerSelection) overrideWith(other ServerSelection) { ss.Cities = helpers.OverrideWithStringSlice(ss.Cities, other.Cities) ss.ISPs = helpers.OverrideWithStringSlice(ss.ISPs, other.ISPs) ss.Hostnames = helpers.OverrideWithStringSlice(ss.Hostnames, other.Hostnames) - ss.Names = helpers.OverrideWithStringSlice(ss.Hostnames, other.Names) + ss.Names = helpers.OverrideWithStringSlice(ss.Names, other.Names) ss.Numbers = helpers.OverrideWithUint16Slice(ss.Numbers, other.Numbers) ss.OwnedOnly = helpers.OverrideWithBool(ss.OwnedOnly, other.OwnedOnly) ss.FreeOnly = helpers.OverrideWithBool(ss.FreeOnly, other.FreeOnly) diff --git a/internal/configuration/sources/env/serverselection.go b/internal/configuration/sources/env/serverselection.go index 1b3f9d3f..aac95dba 100644 --- a/internal/configuration/sources/env/serverselection.go +++ b/internal/configuration/sources/env/serverselection.go @@ -64,7 +64,7 @@ func (r *Reader) readServerSelection(vpnProvider, vpnType string) ( return ss, fmt.Errorf("environment variable OWNED: %w", err) } - // VPNUnlimited only + // VPNUnlimited and ProtonVPN only ss.FreeOnly, err = envToBoolPtr("FREE_ONLY") if err != nil { return ss, fmt.Errorf("environment variable FREE_ONLY: %w", err)