Add guard against null
This commit is contained in:
@@ -69,7 +69,10 @@ class DefaultAssetLibrary extends AssetLibrary {
|
|||||||
type.set (id, AssetType.$$upper(::type::));
|
type.set (id, AssetType.$$upper(::type::));
|
||||||
::end::::end::
|
::end::::end::
|
||||||
|
|
||||||
var assetsPrefix = ApplicationMain.config.assetsPrefix;
|
var assetsPrefix = null;
|
||||||
|
if (ApplicationMain.config != null && Reflect.hasField (ApplicationMain.config, "assetsPrefix")) {
|
||||||
|
assetsPrefix = ApplicationMain.config.assetsPrefix;
|
||||||
|
}
|
||||||
if (assetsPrefix != null) {
|
if (assetsPrefix != null) {
|
||||||
for (k in path.keys()) {
|
for (k in path.keys()) {
|
||||||
path.set(k, assetsPrefix + path[k]);
|
path.set(k, assetsPrefix + path[k]);
|
||||||
|
|||||||
Reference in New Issue
Block a user