mirror of
https://github.com/directus/directus.git
synced 2026-04-25 03:00:53 -04:00
Storage asset transform Presets Only value fix
This commit is contained in:
@@ -82,9 +82,9 @@ router.get(
|
||||
if (transformation.key && allKeys.includes(transformation.key as string) === false)
|
||||
throw new InvalidQueryException(`Key "${transformation.key}" isn't configured.`);
|
||||
return next();
|
||||
} else if (assetSettings.storage_asset_transform === 'shortcut') {
|
||||
} else if (assetSettings.storage_asset_transform === 'presets') {
|
||||
if (allKeys.includes(transformation.key as string)) return next();
|
||||
throw new InvalidQueryException(`Only configured shortcuts can be used in asset generation.`);
|
||||
throw new InvalidQueryException(`Only configured presets can be used in asset generation.`);
|
||||
} else {
|
||||
if (transformation.key && systemKeys.includes(transformation.key as string)) return next();
|
||||
throw new InvalidQueryException(`Dynamic asset generation has been disabled for this project.`);
|
||||
|
||||
Reference in New Issue
Block a user