mirror of
https://github.com/netbirdio/netbird.git
synced 2026-09-29 10:09:07 +02:00
[client] Arm the account prompt only from the wait that owns the flow
This commit is contained in:
@@ -1002,8 +1002,8 @@ func (s *Server) WaitSSOLogin(callerCtx context.Context, msg *proto.WaitSSOLogin
|
|||||||
s.mutex.Lock()
|
s.mutex.Lock()
|
||||||
if s.oauthAuthFlow.flow == flow {
|
if s.oauthAuthFlow.flow == flow {
|
||||||
s.oauthAuthFlow = oauthAuthFlow{}
|
s.oauthAuthFlow = oauthAuthFlow{}
|
||||||
|
s.forceAccountPrompt = true
|
||||||
}
|
}
|
||||||
s.forceAccountPrompt = true
|
|
||||||
s.mutex.Unlock()
|
s.mutex.Unlock()
|
||||||
state.Set(internal.StatusNeedsLogin)
|
state.Set(internal.StatusNeedsLogin)
|
||||||
return nil, gstatus.Errorf(codes.FailedPrecondition, "the login used a different account than this profile; connect again to choose the account")
|
return nil, gstatus.Errorf(codes.FailedPrecondition, "the login used a different account than this profile; connect again to choose the account")
|
||||||
|
|||||||
Reference in New Issue
Block a user