@@ -163,8 +163,8 @@ discard block |
||
163 | 163 | if ($userAgent) { |
164 | 164 | $parser = new Parser($userAgent); |
165 | 165 | $sample->device = ($parser->device->model ?? ''); |
166 | - $sample->browser = ($parser->browser->name ?? '') . ' ' . $parser->browser->getVersion(); |
|
167 | - $sample->os = ($parser->os->name ?? '') . ' ' . $parser->os->getVersion(); |
|
166 | + $sample->browser = ($parser->browser->name ?? '').' '.$parser->browser->getVersion(); |
|
167 | + $sample->os = ($parser->os->name ?? '').' '.$parser->os->getVersion(); |
|
168 | 168 | $sample->mobile = $parser->isMobile(); |
169 | 169 | } |
170 | 170 | // Save the data sample |
@@ -201,7 +201,7 @@ discard block |
||
201 | 201 | $now = round(microtime(true) * 1000); |
202 | 202 | $cache = Craft::$app->getCache(); |
203 | 203 | $then = $cache->get(self::LAST_BEACON_CACHE_KEY); |
204 | - if (($then !== false) && ($now - (int)$then < Webperf::$settings->rateLimitMs)) { |
|
204 | + if (($then !== false) && ($now - (int) $then < Webperf::$settings->rateLimitMs)) { |
|
205 | 205 | $limited = true; |
206 | 206 | Craft::warning('Beacon ignored due to rate limiting', __METHOD__); |
207 | 207 | } |