Merge pull request 'mfa-fixes' (#3517) from moonman/pleroma-fe:mfa-fixes into develop
Reviewed-on: https://git.pleroma.social/pleroma/pleroma-fe/pulls/3517
This commit is contained in:
commit
99d4b5c63e
3 changed files with 4 additions and 3 deletions
1
changelog.d/mfa-fixes.fix
Normal file
1
changelog.d/mfa-fixes.fix
Normal file
|
|
@ -0,0 +1 @@
|
||||||
|
Fix MFA login and recovery code authentication.
|
||||||
|
|
@ -63,8 +63,8 @@ const LoginForm = {
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
.catch((error) => {
|
.catch((error) => {
|
||||||
if (error.errorData?.error === 'mfa_required') {
|
if (error.errorData === 'mfa_required') {
|
||||||
this.requireMFA({ settings: error })
|
this.requireMFA({ settings: error.error })
|
||||||
} else if (error.identifier === 'password_reset_required') {
|
} else if (error.identifier === 'password_reset_required') {
|
||||||
this.$router.push({
|
this.$router.push({
|
||||||
name: 'password-reset',
|
name: 'password-reset',
|
||||||
|
|
|
||||||
|
|
@ -44,7 +44,7 @@ export default {
|
||||||
}
|
}
|
||||||
|
|
||||||
verifyRecoveryCode(data)
|
verifyRecoveryCode(data)
|
||||||
.then((result) => {
|
.then(({ data: result }) => {
|
||||||
this.login(result).then(() => {
|
this.login(result).then(() => {
|
||||||
this.$router.push({ name: 'friends' })
|
this.$router.push({ name: 'friends' })
|
||||||
})
|
})
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue