diff --git a/src/store/modules/users.js b/src/store/modules/users.js index 5d7fb257..0290b888 100644 --- a/src/store/modules/users.js +++ b/src/store/modules/users.js @@ -210,7 +210,11 @@ const users = { dispatch('SuccessMessage') }, async RequirePasswordReset({ dispatch, getters }, user) { - await requirePasswordReset(user.nickname, getters.authHost, getters.token) + try { + await requirePasswordReset(user.nickname, getters.authHost, getters.token) + } catch (_e) { + return + } dispatch('SuccessMessage') }, async SearchUsers({ commit, dispatch, state, getters }, { query, page }) { diff --git a/src/views/users/components/MultipleUsersMenu.vue b/src/views/users/components/MultipleUsersMenu.vue index 1122f237..f3be52cf 100644 --- a/src/views/users/components/MultipleUsersMenu.vue +++ b/src/views/users/components/MultipleUsersMenu.vue @@ -206,7 +206,9 @@ export default { applyAction(filtered, removeTagFn) }, requirePasswordReset: () => { - this.selectedUsers.map(user => this.$store.dispatch('RequirePasswordReset', user)) + const filtered = this.selectedUsers.filter(user => user.local) + filtered.map(user => this.$store.dispatch('RequirePasswordReset', user)) + this.$emit('apply-action') } } },