From: Jerome Jutteau Date: Sun, 15 Mar 2015 09:32:47 +0000 (+0100) Subject: cleanest distinction bewteen 'delete' and 'download' X-Git-Tag: 1.1~144 X-Git-Url: https://git.p6c8.net/jirafeau_project.git/commitdiff_plain/47405a7fcc40dcb517753c22430997fe5bfc4212?hp=aaf7f366cebffa2963241d09d3f899e041ba51d7 cleanest distinction bewteen 'delete' and 'download' Also fix typo --- diff --git a/f.php b/f.php index a5c6228..a1f084a 100644 --- a/f.php +++ b/f.php @@ -58,7 +58,7 @@ if (count ($link) == 0) } $delete_code = ''; -if (isset ($_GET['d']) && !empty ($_GET['d'])) +if (isset ($_GET['d']) && !empty ($_GET['d']) && $_GET['d'] != '1') $delete_code = $_GET['d']; $crypt_key = ''; @@ -66,7 +66,7 @@ if (isset ($_GET['k']) && !empty ($_GET['k'])) $crypt_key = $_GET['k']; $do_download = false; -if (isset ($_GET['d']) && !empty ($_GET['d'])) +if (isset ($_GET['d']) && $_GET['d'] == '1') $do_download = true; $do_preview = false; diff --git a/lib/functions.php b/lib/functions.php index b98486f..89c36b0 100644 --- a/lib/functions.php +++ b/lib/functions.php @@ -443,7 +443,7 @@ jirafeau_upload ($file, $one_time_download, $key, $time, $ip, $crypt, $link_name } /** - * tells if a mime-type is viewable in a browser + * Tells if a mime-type is viewable in a browser * @param $mime the mime type * @returns a boolean telling if a mime type is viewable */