Non-ajax file submissions should throw NoUploadedMediaException
This commit is contained in:
parent
964d13792b
commit
9f87359d04
|
@ -177,7 +177,7 @@ class MediaFile
|
||||||
' partially uploaded.'));
|
' partially uploaded.'));
|
||||||
case UPLOAD_ERR_NO_FILE:
|
case UPLOAD_ERR_NO_FILE:
|
||||||
// No file; probably just a non-AJAX submission.
|
// No file; probably just a non-AJAX submission.
|
||||||
return;
|
throw new NoUploadedMediaException($param);
|
||||||
case UPLOAD_ERR_NO_TMP_DIR:
|
case UPLOAD_ERR_NO_TMP_DIR:
|
||||||
// TRANS: Client exception thrown when a temporary folder is not present to store a file upload.
|
// TRANS: Client exception thrown when a temporary folder is not present to store a file upload.
|
||||||
throw new ClientException(_('Missing a temporary folder.'));
|
throw new ClientException(_('Missing a temporary folder.'));
|
||||||
|
|
Loading…
Reference in New Issue
Block a user