From 005f9dda6d1787e2dea912db2f4f99c0eaf347ee Mon Sep 17 00:00:00 2001 From: Jonas Raoni Soares da Silva Date: Sat, 18 Jan 2025 00:58:06 +0300 Subject: [PATCH] pkp/pkp-lib#10818 Updated syntax --- classes/core/PKPPageRouter.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/classes/core/PKPPageRouter.php b/classes/core/PKPPageRouter.php index be50c4a83f4..e4a2a148522 100644 --- a/classes/core/PKPPageRouter.php +++ b/classes/core/PKPPageRouter.php @@ -500,10 +500,9 @@ private function _getLocaleForUrl(PKPRequest $request, ?Context $context, array */ private function _setLocale(PKPRequest $request, ?string $setLocale): void { - $contextPath = $this->_getRequestedUrlParts(['Core', 'getContextPath'], $request); - $urlLocale = $this->_getRequestedUrlParts(['Core', 'getLocalization'], $request); + $contextPath = $this->_getRequestedUrlParts(Core::getContextPath(...), $request); + $urlLocale = $this->_getRequestedUrlParts(Core::getLocalization(...), $request); $multiLingual = count($this->_getContextAndLocales($request, $contextPath)[1]) > 1; - if (!$setLocale && ($multiLingual ? $urlLocale === Locale::getLocale() : !$urlLocale)) { return; }