diff options
| author | HJ <30-hj@users.noreply.git.pleroma.social> | 2022-05-22 16:38:21 +0000 |
|---|---|---|
| committer | HJ <30-hj@users.noreply.git.pleroma.social> | 2022-05-22 16:38:21 +0000 |
| commit | 3b6d72ef3b57877587e48e35744954945c44a217 (patch) | |
| tree | a38bd995196a52d14d499b46c1b8f256e17a9877 /src/components/settings_modal/tabs/profile_tab.js | |
| parent | a88abc7ee3b78427e40bc4d2346a78e9871d1ba4 (diff) | |
| parent | 069cf3fa87c0d29803275fe66864d5e439cad309 (diff) | |
Merge branch 'revert-a88abc7e' into 'develop'
Revert "Merge branch 'from/develop/tusooa/lang-opts' into 'develop'"
See merge request pleroma/pleroma-fe!1526
Diffstat (limited to 'src/components/settings_modal/tabs/profile_tab.js')
| -rw-r--r-- | src/components/settings_modal/tabs/profile_tab.js | 38 |
1 files changed, 14 insertions, 24 deletions
diff --git a/src/components/settings_modal/tabs/profile_tab.js b/src/components/settings_modal/tabs/profile_tab.js index 8781bb91..f2b48b4b 100644 --- a/src/components/settings_modal/tabs/profile_tab.js +++ b/src/components/settings_modal/tabs/profile_tab.js @@ -8,10 +8,8 @@ import EmojiInput from 'src/components/emoji_input/emoji_input.vue' import suggestor from 'src/components/emoji_input/suggestor.js' import Autosuggest from 'src/components/autosuggest/autosuggest.vue' import Checkbox from 'src/components/checkbox/checkbox.vue' -import InterfaceLanguageSwitcher from 'src/components/interface_language_switcher/interface_language_switcher.vue' import BooleanSetting from '../helpers/boolean_setting.vue' import SharedComputedObject from '../helpers/shared_computed_object.js' -import localeService from 'src/services/locale/locale.service.js' import { library } from '@fortawesome/fontawesome-svg-core' import { @@ -42,8 +40,7 @@ const ProfileTab = { banner: null, bannerPreview: null, background: null, - backgroundPreview: null, - emailLanguage: this.$store.state.users.currentUser.language || '' + backgroundPreview: null } }, components: { @@ -53,8 +50,7 @@ const ProfileTab = { Autosuggest, ProgressButton, Checkbox, - BooleanSetting, - InterfaceLanguageSwitcher + BooleanSetting }, computed: { user () { @@ -115,25 +111,19 @@ const ProfileTab = { }, methods: { updateProfile () { - const params = { - note: this.newBio, - locked: this.newLocked, - // Backend notation. - /* eslint-disable camelcase */ - display_name: this.newName, - fields_attributes: this.newFields.filter(el => el != null), - bot: this.bot, - show_role: this.showRole - /* eslint-enable camelcase */ - } - - if (this.emailLanguage) { - params.language = localeService.internalToBackendLocale(this.emailLanguage) - } - this.$store.state.api.backendInteractor - .updateProfile({ params }) - .then((user) => { + .updateProfile({ + params: { + note: this.newBio, + locked: this.newLocked, + // Backend notation. + /* eslint-disable camelcase */ + display_name: this.newName, + fields_attributes: this.newFields.filter(el => el != null), + bot: this.bot, + show_role: this.showRole + /* eslint-enable camelcase */ + } }).then((user) => { this.newFields.splice(user.fields.length) merge(this.newFields, user.fields) this.$store.commit('addNewUsers', [user]) |
