An array as query string resulted in an error
authorMarcel Werk <burntime@woltlab.com>
Wed, 16 Mar 2022 10:20:11 +0000 (11:20 +0100)
committerMarcel Werk <burntime@woltlab.com>
Wed, 16 Mar 2022 10:20:11 +0000 (11:20 +0100)
wcfsetup/install/files/lib/form/SearchForm.class.php

index 5593637f8fe64494c86c4f3f73fbd5d0dcd5a7ae..db5d1f1970f38138449180a86f6268e892fe594a 100644 (file)
@@ -151,7 +151,7 @@ class SearchForm extends AbstractCaptchaForm
     {
         parent::readParameters();
 
-        if (isset($_REQUEST['q'])) {
+        if (isset($_REQUEST['q']) && \is_string($_REQUEST['q'])) {
             $this->query = StringUtil::trim($_REQUEST['q']);
         }
         if (isset($_REQUEST['username'])) {