Merge pull request #3393 from seefs001/fix/oauth-bind

fix: oauth bind callback handling
This commit is contained in:
Calcium-Ion 2026-03-23 15:02:34 +08:00 committed by GitHub
commit 7693edae53
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 4 additions and 2 deletions

View File

@ -190,7 +190,9 @@ func handleOAuthBind(c *gin.Context, provider oauth.Provider) {
} }
} }
common.ApiSuccessI18n(c, i18n.MsgOAuthBindSuccess, nil) common.ApiSuccessI18n(c, i18n.MsgOAuthBindSuccess, gin.H{
"action": "bind",
})
} }
// findOrCreateOAuthUser finds existing user or creates new user // findOrCreateOAuthUser finds existing user or creates new user

View File

@ -56,7 +56,7 @@ const OAuth2Callback = (props) => {
return; return;
} }
if (message === 'bind') { if (data?.action === 'bind') {
showSuccess(t('绑定成功!')); showSuccess(t('绑定成功!'));
navigate('/console/personal'); navigate('/console/personal');
} else { } else {