1
0
mirror of https://github.com/flextype/flextype.git synced 2025-08-06 05:07:41 +02:00

feat(directives): add ability to disable php using !php

This commit is contained in:
Awilum
2022-09-13 10:14:27 +03:00
parent 517b623595
commit 7ed20b168f

View File

@@ -29,6 +29,10 @@ emitter()->addListener('onEntriesFetchSingleField', static function (): void {
$field = entries()->registry()->get('methods.fetch.field');
if (is_string($field['value']) && strings($field['value'])->contains('!php')) {
return;
}
if (is_string($field['value'])) {
if (strings($field['value'])->contains('@php')) {
ob_start();