mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-15 05:00:49 +08:00
keep some default value be integer 2
This commit is contained in:
@@ -16,7 +16,7 @@ function bark($msg) {
|
||||
if (!mkglobal("id"))
|
||||
bark($lang_delete['std_missing_form_date']);
|
||||
|
||||
$id = $id ?? 0;
|
||||
$id = intval($id ?? 0);
|
||||
if (!$id)
|
||||
die();
|
||||
|
||||
@@ -28,7 +28,7 @@ if (!$row)
|
||||
if ($CURUSER["id"] != $row["owner"] && get_user_class() < $torrentmanage_class)
|
||||
bark($lang_delete['std_not_owner']);
|
||||
|
||||
$rt = $_POST["reasontype"] ?? 0;
|
||||
$rt = intval($_POST["reasontype"] ?? 0);
|
||||
|
||||
if (!is_int($rt) || $rt < 1 || $rt > 5)
|
||||
bark($lang_delete['std_invalid_reason']."$rt.");
|
||||
|
||||
Reference in New Issue
Block a user