diff --git a/changelog.d/pinia-oauth-mfa.skip b/changelog.d/pinia-oauth-mfa.skip new file mode 100644 index 000000000..e69de29bb diff --git a/src/components/mfa_form/recovery_form.js b/src/components/mfa_form/recovery_form.js index 01a62a503..66778b4f6 100644 --- a/src/components/mfa_form/recovery_form.js +++ b/src/components/mfa_form/recovery_form.js @@ -1,5 +1,7 @@ import mfaApi from '../../services/new_api/mfa.js' import { mapState, mapGetters, mapActions, mapMutations } from 'vuex' +import { mapStores } from 'pinia' +import { useOAuthStore } from 'src/stores/oauth.js' import { library } from '@fortawesome/fontawesome-svg-core' import { faTimes @@ -18,9 +20,9 @@ export default { ...mapGetters({ authSettings: 'authFlow/settings' }), + ...mapStores(useOAuthStore), ...mapState({ instance: 'instance', - oauth: 'oauth' }) }, methods: { @@ -28,7 +30,7 @@ export default { ...mapActions({ login: 'authFlow/login' }), clearError () { this.error = false }, submit () { - const { clientId, clientSecret } = this.oauth + const { clientId, clientSecret } = this.oauthStore const data = { clientId, diff --git a/src/components/mfa_form/totp_form.js b/src/components/mfa_form/totp_form.js index 6ee823ed3..e347e017a 100644 --- a/src/components/mfa_form/totp_form.js +++ b/src/components/mfa_form/totp_form.js @@ -1,5 +1,7 @@ import mfaApi from '../../services/new_api/mfa.js' import { mapState, mapGetters, mapActions, mapMutations } from 'vuex' +import { mapStores } from 'pinia' +import { useOAuthStore } from 'src/stores/oauth.js' import { library } from '@fortawesome/fontawesome-svg-core' import { faTimes @@ -18,9 +20,9 @@ export default { ...mapGetters({ authSettings: 'authFlow/settings' }), + ...mapStores(useOAuthStore), ...mapState({ instance: 'instance', - oauth: 'oauth' }) }, methods: { @@ -28,7 +30,7 @@ export default { ...mapActions({ login: 'authFlow/login' }), clearError () { this.error = false }, submit () { - const { clientId, clientSecret } = this.oauth + const { clientId, clientSecret } = this.oauthStore const data = { clientId,