-
-
Notifications
You must be signed in to change notification settings - Fork 74
/
Versions.php
29 lines (25 loc) · 801 Bytes
/
Versions.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
<?php
namespace PackageVersions;
/**
* This is a stub class: it is in place only for scenarios where PackageVersions
* is installed with a `--no-scripts` flag, in which scenarios the Versions class
* is not being replaced.
*
* If you are reading this docBlock inside your `vendor/` dir, then this means
* that PackageVersions didn't correctly install, and is in "fallback" mode.
*/
final class Versions
{
const VERSIONS = [];
private function __construct()
{
}
/**
* @throws \OutOfBoundsException if a version cannot be located
* @throws \UnexpectedValueException if the composer.lock file could not be located
*/
public static function getVersion(string $packageName) : string
{
return FallbackVersions::getVersion($packageName);
}
}