diff options
-rw-r--r-- | app/assets/javascripts/profile/profile.js | 4 | ||||
-rw-r--r-- | changelogs/unreleased/45443-unable-to-save-user-profile-update-with-safari.yml | 5 |
2 files changed, 8 insertions, 1 deletions
diff --git a/app/assets/javascripts/profile/profile.js b/app/assets/javascripts/profile/profile.js index 8cf7f2f23d0..e49c67ffb5c 100644 --- a/app/assets/javascripts/profile/profile.js +++ b/app/assets/javascripts/profile/profile.js @@ -49,13 +49,15 @@ export default class Profile { saveForm() { const self = this; - const formData = new FormData(this.form[0]); + const formData = new FormData(this.form.get(0)); const avatarBlob = this.avatarGlCrop.getBlob(); if (avatarBlob != null) { formData.append('user[avatar]', avatarBlob, 'avatar.png'); } + formData.delete('user[avatar]-trigger'); + axios({ method: this.form.attr('method'), url: this.form.attr('action'), diff --git a/changelogs/unreleased/45443-unable-to-save-user-profile-update-with-safari.yml b/changelogs/unreleased/45443-unable-to-save-user-profile-update-with-safari.yml new file mode 100644 index 00000000000..b18f7aec546 --- /dev/null +++ b/changelogs/unreleased/45443-unable-to-save-user-profile-update-with-safari.yml @@ -0,0 +1,5 @@ +--- +title: Resolve "Unable to save user profile update with Safari" +merge_request: 20676 +author: +type: fixed |