Skip to content

Commit 8492efe

Browse files
committed
Symplify composer scripts
1 parent 6ec48e0 commit 8492efe

File tree

2 files changed

+3
-11
lines changed

2 files changed

+3
-11
lines changed

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@
6969
},
7070
"scripts": {
7171
"phpcs": "php-cs-fixer fix -vvv --diff --dry-run --allow-risky=yes --ansi",
72-
"phpstan": "phpstan analyse -l max -c phpstan.neon src --ansi --memory-limit 192M",
72+
"phpstan": "phpstan analyse -l max -c phpstan.neon src --ansi",
7373
"phpunit": "phpunit --coverage-text",
7474
"test": [
7575
"@phpcs",

src/Idna.php

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -87,11 +87,7 @@ public static function toAscii(string $domain, int $options): IdnaInfo
8787
{
8888
$domain = rawurldecode($domain);
8989
if (1 !== preg_match(self::REGEXP_IDNA_PATTERN, $domain)) {
90-
return IdnaInfo::fromIntl([
91-
'result' => strtolower($domain),
92-
'isTransitionalDifferent' => false,
93-
'errors' => 0,
94-
]);
90+
return IdnaInfo::fromIntl(['result' => strtolower($domain), 'isTransitionalDifferent' => false, 'errors' => 0]);
9591
}
9692

9793
self::supportIdna();
@@ -111,11 +107,7 @@ public static function toAscii(string $domain, int $options): IdnaInfo
111107
public static function toUnicode(string $domain, int $options): IdnaInfo
112108
{
113109
if (false === strpos($domain, 'xn--')) {
114-
return IdnaInfo::fromIntl([
115-
'result' => $domain,
116-
'isTransitionalDifferent' => false,
117-
'errors' => 0,
118-
]);
110+
return IdnaInfo::fromIntl(['result' => $domain, 'isTransitionalDifferent' => false, 'errors' => 0]);
119111
}
120112

121113
self::supportIdna();

0 commit comments

Comments
 (0)