1
0
Fork 0

Add support for ~/+ in addition to - as separator between PHP version and build details, fixes #1322

pull/1326/head
Jordi Boggiano 2012-11-14 10:55:51 +01:00
parent de3188ca7d
commit 172414a1f0
1 changed files with 1 additions and 1 deletions

View File

@ -30,7 +30,7 @@ class PlatformRepository extends ArrayRepository
$prettyVersion = PHP_VERSION; $prettyVersion = PHP_VERSION;
$version = $versionParser->normalize($prettyVersion); $version = $versionParser->normalize($prettyVersion);
} catch (\UnexpectedValueException $e) { } catch (\UnexpectedValueException $e) {
$prettyVersion = preg_replace('#^(.+?)(-.+)?$#', '$1', PHP_VERSION); $prettyVersion = preg_replace('#^([^~+-]+).*$#', '$1', PHP_VERSION);
$version = $versionParser->normalize($prettyVersion); $version = $versionParser->normalize($prettyVersion);
} }