Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 6093675

Browse files
committedOct 28, 2019
fix coding style
1 parent 81cd99e commit 6093675

File tree

3 files changed

+20
-5
lines changed

3 files changed

+20
-5
lines changed
 

‎Parser/Client/Browser.php

+9-3
Original file line numberDiff line numberDiff line change
@@ -256,11 +256,13 @@ class Browser extends AbstractClientParser
256256
'Chrome Frame', 'CoolNovo', 'Chromium', 'ChromePlus', 'Iron', 'RockMelt', 'Amigo', 'TweakStyle', 'Vivaldi',
257257
'Polarity', 'Avast Secure Browser', 'Tenta Browser', 'AOL Shield', 'Samsung Browser', 'Web Explorer',
258258
'Iron Mobile', 'Chrome Webview', 'Whale Browser', 'Seznam Browser', 'QtWebEngine', 'LieBaoFast', 'Kiwi',
259-
'2345 Browser', 'CM Browser', 'Ecosia', 'Mint Browser', 'Mobile Silk', 'DuckDuckGo Privacy Browser', 'Mobile Silk', 'Hawk Turbo Browser', 'Oculus Browser',
259+
'2345 Browser', 'CM Browser', 'Ecosia', 'Mint Browser', 'Mobile Silk', 'DuckDuckGo Privacy Browser',
260+
'Mobile Silk', 'Hawk Turbo Browser', 'Oculus Browser',
260261
],
261262
'Firefox' => [
262263
'Firefox', 'Fennec', 'Firefox Mobile', 'Swiftfox', 'Firebird', 'Phoenix', 'MicroB', 'Epic', 'Waterfox',
263-
'Cunaguaro', 'TenFourFox', 'Qwant Mobile', 'Firefox Rocket', 'IceCat', 'Mobicip', 'Firefox Mobile iOS', 'Basilisk',
264+
'Cunaguaro', 'TenFourFox', 'Qwant Mobile', 'Firefox Rocket', 'IceCat', 'Mobicip', 'Firefox Mobile iOS',
265+
'Basilisk',
264266
],
265267
'Internet Explorer' => ['Internet Explorer', 'IE Mobile', 'Microsoft Edge'],
266268
'Konqueror' => ['Konqueror'],
@@ -370,7 +372,11 @@ public function parse(): ?array
370372
}
371373

372374
// This Exception should never be thrown. If so a defined browser name is missing in $availableBrowsers
373-
throw new \Exception(sprintf('Detected browser name "%s" was not found in $availableBrowsers. Tried to parse user agent: %s', $name, $this->userAgent)); // @codeCoverageIgnore
375+
throw new \Exception(sprintf(
376+
'Detected browser name "%s" was not found in $availableBrowsers. Tried to parse user agent: %s',
377+
$name,
378+
$this->userAgent
379+
)); // @codeCoverageIgnore
374380
}
375381

376382
/**

‎Parser/Client/Browser/Engine.php

+4-1
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,9 @@ public function parse(): ?array
8585
}
8686

8787
// This Exception should never be thrown. If so a defined browser name is missing in $availableEngines
88-
throw new \Exception(sprintf('Detected browser engine was not found in $availableEngines. Tried to parse user agent: %s', $this->userAgent)); // @codeCoverageIgnore
88+
throw new \Exception(sprintf(
89+
'Detected browser engine was not found in $availableEngines. Tried to parse user agent: %s',
90+
$this->userAgent
91+
)); // @codeCoverageIgnore
8992
}
9093
}

‎Parser/Device/AbstractDeviceParser.php

+7-1
Original file line numberDiff line numberDiff line change
@@ -735,7 +735,13 @@ public function parse(): ?array
735735

736736
if (false === $brandId) {
737737
// This Exception should never be thrown. If so a defined brand name is missing in $deviceBrands
738-
throw new \Exception(sprintf("The brand with name '%s' should be listed in the deviceBrands array. Tried to parse user agent: %s", $brand, $this->userAgent)); // @codeCoverageIgnore
738+
throw new \Exception(
739+
sprintf(
740+
"The brand name '%s' needs to be in deviceBrands array. Tried parsing user agent: %s",
741+
$brand,
742+
$this->userAgent
743+
)
744+
); // @codeCoverageIgnore
739745
}
740746

741747
$this->brand = (string) $brandId;

0 commit comments

Comments
 (0)
Please sign in to comment.