]> jfr.im git - uguu.git/blobdiff - api.php
Update README.md
[uguu.git] / api.php
diff --git a/api.php b/api.php
index 8b2a78d7ac75ea0608db24430ab838f05d040259..ad5fc5de00def7c5dbe38332cade6a29315a0462 100644 (file)
--- a/api.php
+++ b/api.php
@@ -5,6 +5,9 @@ if(isset($_GET['d'])) {
     include_once('includes/core.php');
     switch ($_GET['d']) {
         case 'upload':
+        //If no file is being posted, exit
+        if(empty($_FILES['file']['name'])){
+        exit('You fucked up, nothing to do.');}
         //Set the name value to the original filename
        $name = $_FILES['file']['name'];
        $arg = 'custom_original';