File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
src/Umbraco.Web.BackOffice/Security Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -193,8 +193,8 @@ private async Task<SignInResult> AutoLinkAndSignInExternalAccount(ExternalLoginI
193
193
return AutoLinkSignInResult . FailedException ( ex . Message ) ;
194
194
}
195
195
196
- var shouldSignIn = autoLinkOptions . OnExternalLogin ( autoLinkUser , loginInfo ) ;
197
- if ( shouldSignIn == false )
196
+ var shouldLinkUser = autoLinkOptions . OnExternalLogin == null || autoLinkOptions . OnExternalLogin ( autoLinkUser , loginInfo ) ;
197
+ if ( shouldLinkUser == false )
198
198
{
199
199
LogFailedExternalLogin ( loginInfo , autoLinkUser ) ;
200
200
return ExternalLoginSignInResult . NotAllowed ;
@@ -235,8 +235,8 @@ private async Task<SignInResult> AutoLinkAndSignInExternalAccount(ExternalLoginI
235
235
}
236
236
else
237
237
{
238
- var shouldSignIn = autoLinkOptions . OnExternalLogin ( autoLinkUser , loginInfo ) ;
239
- if ( shouldSignIn == false )
238
+ var shouldLinkUser = autoLinkOptions . OnExternalLogin == null || autoLinkOptions . OnExternalLogin ( autoLinkUser , loginInfo ) ;
239
+ if ( shouldLinkUser == false )
240
240
{
241
241
LogFailedExternalLogin ( loginInfo , autoLinkUser ) ;
242
242
return ExternalLoginSignInResult . NotAllowed ;
You can’t perform that action at this time.
0 commit comments