Dont set theme-variant if there is none
This commit is contained in:
parent
0b6435a7c0
commit
e132a102d8
@ -34,9 +34,13 @@ class DauxHelper
|
|||||||
}
|
}
|
||||||
|
|
||||||
$theme = explode('-', $params['html']['theme']);
|
$theme = explode('-', $params['html']['theme']);
|
||||||
|
// do we have a variant or only a theme ?
|
||||||
$params['html']['theme-variant'] = array_pop($theme);
|
if(isset($theme[1])) {
|
||||||
$params['html']['theme'] = implode('-', $theme);
|
$params['html']['theme-variant'] = array_pop($theme);
|
||||||
|
$params['html']['theme'] = implode('-', $theme);
|
||||||
|
} else {
|
||||||
|
$params['html']['theme'] = array_pop($theme);
|
||||||
|
}
|
||||||
|
|
||||||
if (!is_dir($params['themes_path'] . DIRECTORY_SEPARATOR . $params['html']['theme'])) {
|
if (!is_dir($params['themes_path'] . DIRECTORY_SEPARATOR . $params['html']['theme'])) {
|
||||||
throw new \RuntimeException("Theme '{$params['html']['theme']}' not found");
|
throw new \RuntimeException("Theme '{$params['html']['theme']}' not found");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user