diff options
Diffstat (limited to 'server/lib/auth')
-rw-r--r-- | server/lib/auth/oauth-model.ts | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/server/lib/auth/oauth-model.ts b/server/lib/auth/oauth-model.ts index b68cce6d2..81b6529d8 100644 --- a/server/lib/auth/oauth-model.ts +++ b/server/lib/auth/oauth-model.ts | |||
@@ -98,7 +98,14 @@ async function getUser (usernameOrEmail?: string, password?: string, bypassLogin | |||
98 | // Then we just go through a regular login process | 98 | // Then we just go through a regular login process |
99 | if (user.pluginAuth !== null) { | 99 | if (user.pluginAuth !== null) { |
100 | // This user does not belong to this plugin, skip it | 100 | // This user does not belong to this plugin, skip it |
101 | if (user.pluginAuth !== bypassLogin.pluginName) return null | 101 | if (user.pluginAuth !== bypassLogin.pluginName) { |
102 | logger.info( | ||
103 | 'Cannot bypass oauth login by plugin %s because %s has another plugin auth method (%s).', | ||
104 | bypassLogin.pluginName, bypassLogin.user.email, user.pluginAuth | ||
105 | ) | ||
106 | |||
107 | return null | ||
108 | } | ||
102 | 109 | ||
103 | checkUserValidityOrThrow(user) | 110 | checkUserValidityOrThrow(user) |
104 | 111 | ||