Merge pull request #4551 from SHLE1/fix/email-bind-post-method

bug fix: 新版前端email绑定错误
This commit is contained in:
Calcium-Ion 2026-04-30 12:26:48 +08:00 committed by GitHub
commit 22fd1741ab
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 7 additions and 3 deletions

View File

@ -109,8 +109,9 @@ export async function bindEmail(
email: string,
code: string
): Promise<ApiResponse> {
const res = await api.get('/api/oauth/email/bind', {
params: { email, code },
const res = await api.post('/api/oauth/email/bind', {
email,
code,
})
return res.data
}

View File

@ -85,7 +85,10 @@ export async function bindEmail(
email: string,
code: string
): Promise<ApiResponse> {
const res = await api.get(`/api/oauth/email/bind?email=${email}&code=${code}`)
const res = await api.post('/api/oauth/email/bind', {
email,
code,
})
return res.data
}