aboutsummaryrefslogtreecommitdiff
path: root/src/components/media_upload
diff options
context:
space:
mode:
authorRinpatch <rinpatch@sdf.org>2018-12-12 16:38:01 +0300
committerRinpatch <rinpatch@sdf.org>2018-12-12 16:38:01 +0300
commitbf8bb9ce134c8712885e52d005c6d130fca4e553 (patch)
tree563163e079b72343c32eecde199559a406d3dcfa /src/components/media_upload
parent25a04f2294a4ed4d9cf527d8ee2d2899400447dd (diff)
Moved upload errors in user_settings to an array. Moved upload error strings to its separate section in i18n
Diffstat (limited to 'src/components/media_upload')
-rw-r--r--src/components/media_upload/media_upload.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/components/media_upload/media_upload.js b/src/components/media_upload/media_upload.js
index 31d36487..42d900d3 100644
--- a/src/components/media_upload/media_upload.js
+++ b/src/components/media_upload/media_upload.js
@@ -25,7 +25,7 @@ const mediaUpload = {
if (file.size > store.state.instance.uploadlimit) {
const filesize = fileSizeFormatService.fileSizeFormat(file.size)
const allowedsize = fileSizeFormatService.fileSizeFormat(store.state.instance.uploadlimit)
- self.$emit('upload-failed', 'upload_error_file_too_big', {filesize: filesize.num, filesizeunit: filesize.unit, allowedsize: allowedsize.num, allowedsizeunit: allowedsize.unit})
+ self.$emit('upload-failed', 'file_too_big', {filesize: filesize.num, filesizeunit: filesize.unit, allowedsize: allowedsize.num, allowedsizeunit: allowedsize.unit})
return
}
const formData = new FormData()
@@ -39,7 +39,7 @@ const mediaUpload = {
self.$emit('uploaded', fileData)
self.uploading = false
}, (error) => { // eslint-disable-line handle-callback-err
- self.$emit('upload-failed', 'upload_error_generic')
+ self.$emit('upload-failed', 'default')
self.uploading = false
})
},