Skip to content

Commit 7922406

Browse files
fixup
1 parent cc9fca3 commit 7922406

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
11
vendor/
22
.php_cs.cache
33
composer.lock
4-
.idea

src/VersionParser.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -106,10 +106,10 @@ public function normalize($version, $fullVersion = null)
106106
$fullVersion = $version;
107107
}
108108

109-
if (preg_match('{^(\^[^,\s]++) ++as ++([^,\s\^]++)$}', $version, $match) ||
110-
preg_match('{^([^,\s]++) ++as ++(\^[^,\s\^]++)$}', $version, $match) ||
111-
preg_match('{^([^,\s]++) ++as ++(\~[^,\s\^]++)$}', $version, $match) ||
112-
preg_match('{^(\~[^,\s]++) ++as ++([^,\s\^]++)$}', $version, $match)) {
109+
if (preg_match('{^(\^[^,\s]++) ++as ++([^,\s]++)$}', $version, $match) ||
110+
preg_match('{^([^,\s]++) ++as ++(\^[^,\s]++)$}', $version, $match) ||
111+
preg_match('{^([^,\s]++) ++as ++(\~[^,\s]++)$}', $version, $match) ||
112+
preg_match('{^(\~[^,\s]++) ++as ++([^,\s]++)$}', $version, $match)) {
113113
throw new \UnexpectedValueException('the alias must be an exact version');
114114
}
115115

0 commit comments

Comments
 (0)