ref Исправление типов

This commit is contained in:
origami11@yandex.ru 2022-11-24 19:12:00 +03:00
parent a09fc396d8
commit 28429039a4
8 changed files with 24 additions and 98 deletions

View file

@ -88,7 +88,7 @@ class Component
}
}
public function getTemplateName($_registry/*: Settings*/) {
public function getTemplateName($_registry/*: \ctiso\Settings*/) {
return (isset($_COOKIE['with_template']) && preg_match('/^[\w\d-]{3,20}$/', $_COOKIE['with_template']))
? $_COOKIE['with_template'] : ($_registry ? $_registry->get('site', 'template') : 'modern');
}
@ -147,7 +147,7 @@ class Component
}
public function getTemplatePath($name) {
$registry/*: Settings*/ = $this->config;
$registry/*: \ctiso\Settings*/ = $this->config;
// Брать настройки из куков если есть
$template = ($this->template) ? $this->template : $this->getTemplateName($registry);
foreach ($this->viewPath as $index => $viewPath) {