From e1ecc535875825d89a49e2bf7850be351ea749f4 Mon Sep 17 00:00:00 2001 From: Ioannis Igoumenos Date: Thu, 12 Sep 2024 20:43:01 +0300 Subject: [PATCH] Fix broken global search,get primary link error --- app/src/Controller/AppController.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/src/Controller/AppController.php b/app/src/Controller/AppController.php index efb407076..35b51d485 100644 --- a/app/src/Controller/AppController.php +++ b/app/src/Controller/AppController.php @@ -318,7 +318,8 @@ protected function populatedPrimaryLink(string $potentialPrimaryLink): Object : null; $cur = new \stdClass(); - $cur->value = $this->request->getQuery($potentialPrimaryLink); + // Check both the query parameters(GET request) and the body(POST request). + $cur->value = $this->request->getQuery($potentialPrimaryLink) ?? $this->request->getData($potentialPrimaryLink); // We found a populated primary link. Store the attribute and break the loop. $cur->attr = $potentialPrimaryLink; if($potentialPlugin) {