@@ -69,8 +69,8 @@ |
||
| 69 | 69 | } else { |
| 70 | 70 | $targetFieldUid = $targetFieldIdOrUid; |
| 71 | 71 | } |
| 72 | - $return[$targetFieldUid] = \array_map(function (array $rules) { |
|
| 73 | - return \array_map(function (array $rule) { |
|
| 72 | + $return[$targetFieldUid] = \array_map(function(array $rules) { |
|
| 73 | + return \array_map(function(array $rule) { |
|
| 74 | 74 | $fieldIdOrUid = $rule['fieldId'] ?? $rule['field']; |
| 75 | 75 | if (!StringHelper::isUUID($fieldIdOrUid)) { |
| 76 | 76 | $fieldUid = Db::uidById('{{%fields}}', $fieldIdOrUid); |
@@ -52,7 +52,7 @@ |
||
| 52 | 52 | return true; |
| 53 | 53 | } |
| 54 | 54 | |
| 55 | - /** |
|
| 55 | + /** |
|
| 56 | 56 | * @inheritdoc |
| 57 | 57 | */ |
| 58 | 58 | public function safeDown() |
@@ -256,8 +256,8 @@ discard block |
||
| 256 | 256 | $conditionals = Json::decodeIfJson($conditionals); |
| 257 | 257 | foreach ($conditionals as $targetFieldId => $statements) { |
| 258 | 258 | $targetFieldUid = Db::uidById('{{%fields}}', $targetFieldId); |
| 259 | - $return[$targetFieldUid] = \array_map(function (array $rules) { |
|
| 260 | - return \array_map(function (array $rule) { |
|
| 259 | + $return[$targetFieldUid] = \array_map(function(array $rules) { |
|
| 260 | + return \array_map(function(array $rule) { |
|
| 261 | 261 | return [ |
| 262 | 262 | 'field' => Db::uidById('{{%fields}}', $rule['fieldId']), |
| 263 | 263 | 'compare' => $rule['compare'], |
@@ -283,8 +283,8 @@ discard block |
||
| 283 | 283 | $conditionals = Json::decodeIfJson($conditionals); |
| 284 | 284 | foreach ($conditionals as $targetFieldUid => $statements) { |
| 285 | 285 | $targetFieldId = Db::idByUid('{{%fields}}', $targetFieldUid); |
| 286 | - $return[$targetFieldId] = \array_map(function (array $rules) { |
|
| 287 | - return \array_map(function (array $rule) { |
|
| 286 | + $return[$targetFieldId] = \array_map(function(array $rules) { |
|
| 287 | + return \array_map(function(array $rule) { |
|
| 288 | 288 | return [ |
| 289 | 289 | 'fieldId' => Db::idByUid('{{%fields}}', $rule['field']), |
| 290 | 290 | 'compare' => $rule['compare'], |
@@ -88,7 +88,7 @@ discard block |
||
| 88 | 88 | Event::on( |
| 89 | 89 | Plugins::class, |
| 90 | 90 | Plugins::EVENT_AFTER_INSTALL_PLUGIN, |
| 91 | - function (PluginEvent $event) { |
|
| 91 | + function(PluginEvent $event) { |
|
| 92 | 92 | if ($event->plugin === $this) { |
| 93 | 93 | $this->reasons->clearCache(); |
| 94 | 94 | } |
@@ -98,7 +98,7 @@ discard block |
||
| 98 | 98 | Event::on( |
| 99 | 99 | Plugins::class, |
| 100 | 100 | Plugins::EVENT_AFTER_UNINSTALL_PLUGIN, |
| 101 | - function (PluginEvent $event) { |
|
| 101 | + function(PluginEvent $event) { |
|
| 102 | 102 | if ($event->plugin === $this) { |
| 103 | 103 | $this->reasons->clearCache(); |
| 104 | 104 | } |
@@ -109,7 +109,7 @@ discard block |
||
| 109 | 109 | Event::on( |
| 110 | 110 | Fields::class, |
| 111 | 111 | Fields::EVENT_AFTER_SAVE_FIELD_LAYOUT, |
| 112 | - function (FieldLayoutEvent $event) { |
|
| 112 | + function(FieldLayoutEvent $event) { |
|
| 113 | 113 | if (Craft::$app->getRequest()->getIsConsoleRequest()) { |
| 114 | 114 | return; |
| 115 | 115 | } |
@@ -223,7 +223,7 @@ discard block |
||
| 223 | 223 | Event::on( |
| 224 | 224 | View::class, |
| 225 | 225 | View::EVENT_BEFORE_RENDER_TEMPLATE, |
| 226 | - function (/** @scrutinizer ignore-unused */ TemplateEvent $event) { |
|
| 226 | + function(/** @scrutinizer ignore-unused */ TemplateEvent $event) { |
|
| 227 | 227 | try { |
| 228 | 228 | Craft::$app->getView()->registerAssetBundle(ReasonsAssetBundle::class); |
| 229 | 229 | } catch (InvalidConfigException $e) { |