@@ -92,7 +92,7 @@ discard block |
||
| 92 | 92 | |
| 93 | 93 | // Add option to the Clear Caches utility to invalidate all flagged caches |
| 94 | 94 | Event::on(ClearCaches::class, ClearCaches::EVENT_REGISTER_CACHE_OPTIONS, |
| 95 | - static function (RegisterCacheOptionsEvent $event) { |
|
| 95 | + static function(RegisterCacheOptionsEvent $event) { |
|
| 96 | 96 | $event->options[] = [ |
| 97 | 97 | 'key' => 'cacheflag-flagged-caches', |
| 98 | 98 | 'label' => Craft::t('cache-flag', 'Flagged template caches'), |
@@ -106,7 +106,7 @@ discard block |
||
| 106 | 106 | Event::on( |
| 107 | 107 | CraftVariable::class, |
| 108 | 108 | CraftVariable::EVENT_INIT, |
| 109 | - function (Event $event) { |
|
| 109 | + function(Event $event) { |
|
| 110 | 110 | /** @var CraftVariable $variable */ |
| 111 | 111 | $variable = $event->sender; |
| 112 | 112 | $variable->set('cacheFlagCp', CpVariable::class); |
@@ -156,7 +156,7 @@ discard block |
||
| 156 | 156 | Event::on( |
| 157 | 157 | Plugins::class, |
| 158 | 158 | Plugins::EVENT_AFTER_UNINSTALL_PLUGIN, |
| 159 | - function (PluginEvent $event) { |
|
| 159 | + function(PluginEvent $event) { |
|
| 160 | 160 | if ($event->plugin === $this) { |
| 161 | 161 | Craft::$app->getProjectConfig()->remove('cacheFlags'); |
| 162 | 162 | } |
@@ -173,7 +173,7 @@ discard block |
||
| 173 | 173 | Event::on( |
| 174 | 174 | Elements::class, |
| 175 | 175 | Elements::EVENT_AFTER_SAVE_ELEMENT, |
| 176 | - function (ElementEvent $event) { |
|
| 176 | + function(ElementEvent $event) { |
|
| 177 | 177 | $element = $event->element; |
| 178 | 178 | if (!$element || ElementHelper::isDraftOrRevision($element)) { |
| 179 | 179 | return; |
@@ -186,7 +186,7 @@ discard block |
||
| 186 | 186 | Event::on( |
| 187 | 187 | Elements::class, |
| 188 | 188 | Elements::EVENT_BEFORE_DELETE_ELEMENT, |
| 189 | - function (ElementEvent $event) { |
|
| 189 | + function(ElementEvent $event) { |
|
| 190 | 190 | $element = $event->element; |
| 191 | 191 | if (!$element || ElementHelper::isDraftOrRevision($element)) { |
| 192 | 192 | return; |
@@ -199,7 +199,7 @@ discard block |
||
| 199 | 199 | Event::on( |
| 200 | 200 | Structures::class, |
| 201 | 201 | Structures::EVENT_AFTER_MOVE_ELEMENT, |
| 202 | - function (MoveElementEvent $event) { |
|
| 202 | + function(MoveElementEvent $event) { |
|
| 203 | 203 | $element = $event->element; |
| 204 | 204 | if (!$element || ElementHelper::isDraftOrRevision($element)) { |
| 205 | 205 | return; |
@@ -212,7 +212,7 @@ discard block |
||
| 212 | 212 | Event::on( |
| 213 | 213 | Elements::class, |
| 214 | 214 | Elements::EVENT_AFTER_PERFORM_ACTION, |
| 215 | - function (ElementActionEvent $event) { |
|
| 215 | + function(ElementActionEvent $event) { |
|
| 216 | 216 | |
| 217 | 217 | /* @var ElementQueryInterface|null $criteria */ |
| 218 | 218 | $criteria = $event->criteria; |