[client/server] Allow clearing pre-shared key via SetConfig

The daemon ignored an empty OptionalPreSharedKey, so a UI/CLI request to
clear the pre-shared key was silently dropped. Pass the pointer through
unconditionally — profilemanager already handles the empty-string case.
This commit is contained in:
Zoltán Papp
2026-05-11 11:02:39 +02:00
parent a5cc8da054
commit 08f52f4517

View File

@@ -341,9 +341,7 @@ func (s *Server) SetConfig(callerCtx context.Context, msg *proto.SetConfigReques
}
if msg.OptionalPreSharedKey != nil {
if *msg.OptionalPreSharedKey != "" {
config.PreSharedKey = msg.OptionalPreSharedKey
}
config.PreSharedKey = msg.OptionalPreSharedKey
}
if msg.CleanDNSLabels {