Skip to content

Kirby 5.0.4

FilePermissions::canFromCache()

Quickly determines a permission for the current user role and model blueprint unless dynamic checking is required

FilePermissions::canFromCache(Kirby\Cms\ModelWithContent|Kirby\Cms\Language $model, string $action, bool $default = false): bool

Parameters

Name Type Default
$modelrequired Kirby\Cms\ModelWithContentorKirby\Cms\Language no default value
$actionrequired string no default value
$default bool false

Return type

bool

Parent class

Kirby\Cms\FilePermissions inherited from Kirby\Cms\ModelPermissions