From db654595fba6f3f02d6bdee499b22af705e3801f Mon Sep 17 00:00:00 2001 From: Fascinated Date: Sun, 9 Apr 2023 17:40:37 +0100 Subject: [PATCH] part 2 of below --- upload.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/upload.php b/upload.php index 11d1be3..66402c4 100644 --- a/upload.php +++ b/upload.php @@ -118,18 +118,18 @@ try { 'url' => $finalName, 'timeTaken' => getTimeTaken() )); - } else { - returnJson(array( - 'status' => 'ERROR', - 'url' => 'Failed to save file. Check the permissions of the upload directory.', - 'timeTaken' => getTimeTaken() - )); + die(); } + returnJson(array( + 'status' => 'ERROR', + 'url' => 'Failed to save file. Check the permissions of the upload directory.', + 'timeTaken' => getTimeTaken() + )); die(); } returnJson(array( 'status' => 'OK', - 'url' => 'File uploaded successfully', + 'url' => $finalName, 'timeTaken' => getTimeTaken() )); die();