@@ -73,7 +73,7 @@ |
||
| 73 | 73 | |
| 74 | 74 | // Render the template with our vars passed in |
| 75 | 75 | try { |
| 76 | - $htmlText = Craft::$app->view->renderTemplate('webperf/' . $templatePath, $params); |
|
| 76 | + $htmlText = Craft::$app->view->renderTemplate('webperf/'.$templatePath, $params); |
|
| 77 | 77 | if ($minifier) { |
| 78 | 78 | // If SEOmatic is installed, get the title from it |
| 79 | 79 | $minify = Craft::$app->getPlugins()->getPlugin(self::MINIFY_PLUGIN_HANDLE); |
@@ -40,7 +40,7 @@ |
||
| 40 | 40 | ->from(['{{%webperf_data_samples}}']) |
| 41 | 41 | ->where(['not', [$column => null]]) |
| 42 | 42 | ; |
| 43 | - if ((int)$siteId !== 0) { |
|
| 43 | + if ((int) $siteId !== 0) { |
|
| 44 | 44 | $query->andWhere(['siteId' => $siteId]); |
| 45 | 45 | } |
| 46 | 46 | return $query->count(); |
@@ -69,7 +69,7 @@ discard block |
||
| 69 | 69 | 'AVG('.$column.') AS avg', |
| 70 | 70 | ]) |
| 71 | 71 | ->where("dateUpdated >= ( CURDATE() - INTERVAL '{$days}' DAY )"); |
| 72 | - if ((int)$siteId !== 0) { |
|
| 72 | + if ((int) $siteId !== 0) { |
|
| 73 | 73 | $query->andWhere(['siteId' => $siteId]); |
| 74 | 74 | } |
| 75 | 75 | $stats = $query->all(); |
@@ -82,7 +82,7 @@ discard block |
||
| 82 | 82 | 'AVG("'.$column.'") AS avg', |
| 83 | 83 | ]) |
| 84 | 84 | ->where("\"dateUpdated\" >= ( CURRENT_TIMESTAMP - INTERVAL '{$days} days' )"); |
| 85 | - if ((int)$siteId !== 0) { |
|
| 85 | + if ((int) $siteId !== 0) { |
|
| 86 | 86 | $query->andWhere(['siteId' => $siteId]); |
| 87 | 87 | } |
| 88 | 88 | $stats = $query->all(); |
@@ -127,7 +127,7 @@ discard block |
||
| 127 | 127 | 'AVG('.$column.') AS avg', |
| 128 | 128 | ]) |
| 129 | 129 | ->where("dateUpdated >= ( CURDATE() - INTERVAL '{$days}' DAY )"); |
| 130 | - if ((int)$siteId !== 0) { |
|
| 130 | + if ((int) $siteId !== 0) { |
|
| 131 | 131 | $query->andWhere(['siteId' => $siteId]); |
| 132 | 132 | } |
| 133 | 133 | $query |
@@ -147,7 +147,7 @@ discard block |
||
| 147 | 147 | 'AVG("'.$column.'") AS avg', |
| 148 | 148 | ]) |
| 149 | 149 | ->where("\"dateUpdated\" >= ( CURRENT_TIMESTAMP - INTERVAL '{$days} days' )"); |
| 150 | - if ((int)$siteId !== 0) { |
|
| 150 | + if ((int) $siteId !== 0) { |
|
| 151 | 151 | $query->andWhere(['siteId' => $siteId]); |
| 152 | 152 | } |
| 153 | 153 | $query |