1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-01 20:30:39 +02:00

Set 'front' by default if theme.xml library scope is missing.

This commit is contained in:
Cameron
2021-02-13 06:50:17 -08:00
parent 800f8734bf
commit 5ec3aa7245
3 changed files with 6 additions and 3 deletions

View File

@@ -1095,7 +1095,7 @@ class e_theme
$vars['library'][] = array(
'name' => $val['@attributes']['name'],
'version' => varset($val['@attributes']['version']),
'scope' => varset($val['@attributes']['scope']),
'scope' => varset($val['@attributes']['scope'], 'front'),
);
}

View File

@@ -27,6 +27,7 @@
}
$this->tm->clearCache();
e107::getTheme()->clearCache();
}
@@ -203,6 +204,7 @@
),
),
),
);
foreach($tests as $index => $var)
@@ -216,6 +218,7 @@
$this->assertSame($var['expected'], $result, 'Test #'.$index.' failed.');
}
}

View File

@@ -6,8 +6,8 @@
<category>generic</category>
<compliance xhtml="1.1" css="2.1" />
<libraries>
<library name="bootstrap" version="3" scope="all"/>
<library name="fontawesome" version="4" scope="all"/>
<library name="bootstrap" version="3" scope="front"/>
<library name="fontawesome" version="4" scope="front"/>
</libraries>
<plugins>
<plugin name='chatbox_menu' url='core' />