added has_php helper.
This commit is contained in:
parent
3dab550681
commit
8b2f3e8421
|
@ -373,4 +373,15 @@ function value($value)
|
||||||
function with($object)
|
function with($object)
|
||||||
{
|
{
|
||||||
return $object;
|
return $object;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Determine if the current version of PHP is at least the supplied version.
|
||||||
|
*
|
||||||
|
* @param string $version
|
||||||
|
* @return bool
|
||||||
|
*/
|
||||||
|
function has_php($version)
|
||||||
|
{
|
||||||
|
return version_compare(PHP_VERSION, $version) >= 0;
|
||||||
}
|
}
|
Loading…
Reference in New Issue