mirror of
https://github.com/qdm12/gluetun.git
synced 2026-06-19 18:04:09 +02:00
feat(protonvpn): support up to 5 forwarded ports (#3208)
This commit is contained in:
@@ -69,7 +69,11 @@ func (s *Service) SetPortsForwarded(ctx context.Context, ports []uint16) (err er
|
||||
return fmt.Errorf("cleaning up: %w", err)
|
||||
}
|
||||
|
||||
err = s.onNewPorts(ctx, ports)
|
||||
internalToExternalPorts := make(map[uint16]uint16, len(ports))
|
||||
for _, port := range ports {
|
||||
internalToExternalPorts[port] = port
|
||||
}
|
||||
err = s.onNewPorts(ctx, internalToExternalPorts)
|
||||
if err != nil {
|
||||
return fmt.Errorf("handling new ports: %w", err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user