mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-05 09:41:40 +09:00
Throw exception instead of just exiting
This commit is contained in:
parent
a3cc3a9781
commit
42b879d628
1 changed files with 4 additions and 1 deletions
|
|
@ -29,7 +29,10 @@ class FileController extends File
|
|||
$file_info = Context::get('Filedata');
|
||||
|
||||
// An error appears if not a normally uploaded file
|
||||
if(!$file_info || !is_uploaded_file($file_info['tmp_name'])) exit();
|
||||
if (!$file_info || !is_uploaded_file($file_info['tmp_name']))
|
||||
{
|
||||
throw new Rhymix\Framework\Exceptions\InvalidRequest();
|
||||
}
|
||||
|
||||
// Validate editor_sequence and module_srl.
|
||||
$editor_sequence = Context::get('editor_sequence');
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue