logo

pleroma-fe

My custom branche(s) on git.pleroma.social/pleroma/pleroma-fe
commit: 9305dad0057bc3a729b338fa11aa0f867dbb6c2f
parent: c8caa477d7f9d6b793ba0f75c736510f47298014
Author: HJ <spam@hjkos.com>
Date:   Thu, 24 Jan 2019 12:15:46 +0000

Merge branch 'fix/hide-network-setting' into 'develop'

Always send "hide_network" when updating user profile

See merge request pleroma/pleroma-fe!471

Diffstat:

Msrc/services/api/api.service.js5+++--
1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/services/api/api.service.js b/src/services/api/api.service.js @@ -129,13 +129,14 @@ const updateBanner = ({credentials, params}) => { // location // description const updateProfile = ({credentials, params}) => { + // Always include these fields, because they might be empty or false + const fields = ['description', 'locked', 'no_rich_text', 'hide_network'] let url = PROFILE_UPDATE_URL const form = new FormData() each(params, (value, key) => { - /* Always include description, no_rich_text and locked, because it might be empty or false */ - if (key === 'description' || key === 'locked' || key === 'no_rich_text' || value) { + if (fields.includes(key) || value) { form.append(key, value) } })