@@ -157,7 +157,7 @@ discard block |
||
157 | 157 | Event::on( |
158 | 158 | Plugins::class, |
159 | 159 | Plugins::EVENT_AFTER_INSTALL_PLUGIN, |
160 | - function (PluginEvent $event) { |
|
160 | + function(PluginEvent $event) { |
|
161 | 161 | if ($event->plugin === $this) { |
162 | 162 | // Invalidate our caches after we've been installed |
163 | 163 | $this->clearAllCaches(); |
@@ -185,7 +185,7 @@ discard block |
||
185 | 185 | Event::on( |
186 | 186 | CraftVariable::class, |
187 | 187 | CraftVariable::EVENT_INIT, |
188 | - function (Event $event) { |
|
188 | + function(Event $event) { |
|
189 | 189 | /** @var CraftVariable $variable */ |
190 | 190 | $variable = $event->sender; |
191 | 191 | $variable->set('webperf', WebperfVariable::class); |
@@ -195,7 +195,7 @@ discard block |
||
195 | 195 | Event::on( |
196 | 196 | Plugins::class, |
197 | 197 | Plugins::EVENT_AFTER_LOAD_PLUGINS, |
198 | - function () { |
|
198 | + function() { |
|
199 | 199 | // Install these only after all other plugins have loaded |
200 | 200 | $request = Craft::$app->getRequest(); |
201 | 201 | // Only respond to non-console site requests |
@@ -219,7 +219,7 @@ discard block |
||
219 | 219 | Event::on( |
220 | 220 | UrlManager::class, |
221 | 221 | UrlManager::EVENT_REGISTER_SITE_URL_RULES, |
222 | - function (RegisterUrlRulesEvent $event) { |
|
222 | + function(RegisterUrlRulesEvent $event) { |
|
223 | 223 | Craft::debug( |
224 | 224 | 'UrlManager::EVENT_REGISTER_SITE_URL_RULES', |
225 | 225 | __METHOD__ |
@@ -242,7 +242,7 @@ discard block |
||
242 | 242 | Event::on( |
243 | 243 | UrlManager::class, |
244 | 244 | UrlManager::EVENT_REGISTER_CP_URL_RULES, |
245 | - function (RegisterUrlRulesEvent $event) { |
|
245 | + function(RegisterUrlRulesEvent $event) { |
|
246 | 246 | Craft::debug( |
247 | 247 | 'UrlManager::EVENT_REGISTER_CP_URL_RULES', |
248 | 248 | __METHOD__ |
@@ -258,7 +258,7 @@ discard block |
||
258 | 258 | Event::on( |
259 | 259 | Dashboard::class, |
260 | 260 | Dashboard::EVENT_REGISTER_WIDGET_TYPES, |
261 | - function (RegisterComponentTypesEvent $event) { |
|
261 | + function(RegisterComponentTypesEvent $event) { |
|
262 | 262 | $event->types[] = MetricsWidget::class; |
263 | 263 | } |
264 | 264 | ); |
@@ -266,7 +266,7 @@ discard block |
||
266 | 266 | Event::on( |
267 | 267 | UserPermissions::class, |
268 | 268 | UserPermissions::EVENT_REGISTER_PERMISSIONS, |
269 | - function (RegisterUserPermissionsEvent $event) { |
|
269 | + function(RegisterUserPermissionsEvent $event) { |
|
270 | 270 | Craft::debug( |
271 | 271 | 'UserPermissions::EVENT_REGISTER_PERMISSIONS', |
272 | 272 | __METHOD__ |
@@ -291,7 +291,7 @@ discard block |
||
291 | 291 | Event::on( |
292 | 292 | View::class, |
293 | 293 | View::EVENT_END_PAGE, |
294 | - function () { |
|
294 | + function() { |
|
295 | 295 | Craft::debug( |
296 | 296 | 'View::EVENT_END_PAGE', |
297 | 297 | __METHOD__ |
@@ -300,7 +300,7 @@ discard block |
||
300 | 300 | $target = Craft::$app->getLog()->targets['debug']; |
301 | 301 | $messages = $target->filterMessages($target->messages, Logger::LEVEL_PROFILE); |
302 | 302 | $timings = Craft::getLogger()->calculateTimings($messages); |
303 | - Craft::error('whore ' . print_r($timings, true), __METHOD__); |
|
303 | + Craft::error('whore '.print_r($timings, true), __METHOD__); |
|
304 | 304 | // The page is done rendering, include our beacon |
305 | 305 | if (Webperf::$settings->includeBeacon && $view->getIsRenderingPageTemplate()) { |
306 | 306 | switch (self::$renderType) { |
@@ -318,7 +318,7 @@ discard block |
||
318 | 318 | Event::on( |
319 | 319 | View::class, |
320 | 320 | View::EVENT_END_BODY, |
321 | - function () { |
|
321 | + function() { |
|
322 | 322 | Craft::debug( |
323 | 323 | 'View::EVENT_END_BODY', |
324 | 324 | __METHOD__ |