logo

pleroma-fe

My custom branche(s) on git.pleroma.social/pleroma/pleroma-fe git clone https://hacktivis.me/git/pleroma-fe.git
commit: cd9c026042f045037ff9c4f71bda2eb5dde8f3df
parent 9ffe5c2ef53cfefa96ff958a4922ec3b43e1329d
Author: Tusooa Zhu <tusooa@kazv.moe>
Date:   Thu, 24 Mar 2022 16:55:39 -0400

Log errors when listing aliases

Diffstat:

Msrc/components/settings_modal/tabs/security_tab/security_tab.js6+++++-
Msrc/components/settings_modal/tabs/security_tab/security_tab.vue12++++++++++++
2 files changed, 17 insertions(+), 1 deletion(-)

diff --git a/src/components/settings_modal/tabs/security_tab/security_tab.js b/src/components/settings_modal/tabs/security_tab/security_tab.js @@ -21,6 +21,7 @@ const SecurityTab = { movedAccount: false, moveAccountError: false, aliases: [], + listAliasesError: false, addAliasTarget: '', addedAlias: false, addAliasError: false @@ -136,9 +137,12 @@ const SecurityTab = { }, fetchAliases () { this.$store.state.api.backendInteractor.listAliases() - .catch(() => {}) .then((res) => { this.aliases = res.aliases + this.listAliasesError = false + }) + .catch((error) => { + this.listAliasesError = error.error }) }, logout () { diff --git a/src/components/settings_modal/tabs/security_tab/security_tab.vue b/src/components/settings_modal/tabs/security_tab/security_tab.vue @@ -130,6 +130,18 @@ </tr> </tbody> </table> + <div + v-if="listAliasesError" + class="alert error" + > + {{ $t('settings.list_aliases_error', { error }) }} + <FAIcon + class="fa-scale-110 fa-old-padding" + icon="times" + :title="$t('settings.hide_list_aliases_error_action')" + @click="listAliasesError = false" + /> + </div> <div> <i18n path="settings.new_alias_target"