Unset $matches['token'] after use

Causes a parameter error in later versions of PHP
This commit is contained in:
discomrade 2022-02-27 10:11:03 -01:00 committed by -
parent 98ee082ea3
commit c228c5a7bb

View File

@ -173,6 +173,7 @@ foreach ($pages as $uri => $handler) {
$secure_post_only = isset($m[1]);
if (!$secure_post_only || $_SERVER['REQUEST_METHOD'] == 'POST') {
$token = isset($matches['token']) ? $matches['token'] : (isset($_POST['token']) ? $_POST['token'] : false);
unset($matches['token']);
if ($token === false) {
if ($secure_post_only)