Fix rendering assets with no settings

This commit is contained in:
rijkvanzanten
2020-10-20 16:38:52 -04:00
parent 2d12e73871
commit cd676119c2

View File

@@ -79,7 +79,10 @@ router.get(
];
// For use in the next request handler
res.locals.shortcuts = [...SYSTEM_ASSET_ALLOW_LIST, ...assetSettings.storage_asset_presets];
res.locals.shortcuts = [
...SYSTEM_ASSET_ALLOW_LIST,
...(assetSettings.storage_asset_presets || []),
];
res.locals.transformation = transformation;
if (Object.keys(transformation).length === 0) {