1
0
mirror of https://github.com/typemill/typemill.git synced 2025-08-01 11:50:28 +02:00

Merge branch 'develop' of https://github.com/typemill/typemill into develop

This commit is contained in:
trendschau
2021-03-30 19:58:21 +02:00

View File

@@ -33,7 +33,9 @@ class Settings
if(!isset($settings['theme']) OR !file_exists($themefolder . $settings['theme']))
{
# scan theme folder and get the first theme
$themes = array_diff(scandir($themefolder), array('..', '.'));
$themes = array_filter(scandir($themefolder), function ($item) use($themefolder) {
return is_dir($themefolder . $item) && strpos($item, '.') !== 0;
});
$firsttheme = reset($themes);
# if there is a theme with an index.twig-file