Commit 7693edae by Calcium-Ion Committed by GitHub

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

fix: oauth bind callback handling
parents d6982c81 f40eb4e5
...@@ -190,7 +190,9 @@ func handleOAuthBind(c *gin.Context, provider oauth.Provider) { ...@@ -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
......
...@@ -56,7 +56,7 @@ const OAuth2Callback = (props) => { ...@@ -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 {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment