Skip to content
This repository was archived by the owner on Dec 11, 2024. It is now read-only.

Commit f7bc033

Browse files
committed
#1080 redirect with 301 http code
1 parent 994e3fe commit f7bc033

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

module/Rubedo/src/Rubedo/Frontoffice/Controller/IndexController.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ public function indexAction()
183183
}
184184
$lang = Manager::getService('CurrentLocalization')->resolveLocalization($this->_site['id'], $this->params('locale'), $cookieValue);
185185
if ($lang && !$this->params('locale')) {
186-
return $this->redirect()->toUrl(strtolower(array_pop($this->_site['protocol'])) . '://' . $domain . '/' . $lang . $uri->getPath() . '?' . $uri->getQuery());
186+
return $this->redirect()->toUrl(strtolower(array_pop($this->_site['protocol'])) . '://' . $domain . '/' . $lang . $uri->getPath() . '?' . $uri->getQuery())->setStatusCode(301);
187187
}
188188

189189
if ($domain && !$this->_site['useBrowserLanguage']) {

0 commit comments

Comments
 (0)