summaryrefslogtreecommitdiff
path: root/report.php
diff options
context:
space:
mode:
authorAppleman1234 <applemansigloo@gmail.com>2022-09-25 13:30:13 +1000
committerAppleman1234 <applemansigloo@gmail.com>2022-09-25 13:30:13 +1000
commit2c69095a1edf7474073451285238659d0f62ce3f (patch)
tree5dee476605402c66dc2853d0836b29f6aedae62b /report.php
parente9a61e2fbbd930eaa80d6a5f33420cedc59d748c (diff)
PHP8.1 fixes from Rector
Diffstat (limited to 'report.php')
-rw-r--r--report.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/report.php b/report.php
index e09b1075..c55d0d93 100644
--- a/report.php
+++ b/report.php
@@ -1,10 +1,10 @@
<?php
include 'inc/functions.php';
$global = isset($_GET['global']);
-$post = (isset($_GET['post']) ? $_GET['post'] : false);
-$board = (isset($_GET['board']) ? $_GET['board'] : false);
+$post = ($_GET['post'] ?? false);
+$board = ($_GET['board'] ?? false);
-if (!$post || !preg_match('/^delete_\d+$/', $post) || !$board || !openBoard($board)) {
+if (!$post || !preg_match('/^delete_\d+$/', (string) $post) || !$board || !openBoard($board)) {
header('HTTP/1.1 400 Bad Request');
error(_('Bad request.'));
}