Commit ab1a8d10 authored by Luke Bennett's avatar Luke Bennett

Delete unneeded user avatar formData

parent 10bd8002
......@@ -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'),
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment