Add env method to request

This commit is contained in:
Maarten 2020-02-13 19:17:02 +01:00
parent 40e64ef9b7
commit a047e15f7e

View file

@ -2,6 +2,7 @@
namespace Runtime\Http;
use Runtime\Config\Env;
use Runtime\Exceptions\Exceptions\MalformedUrlException;
use Runtime\Http\Input\InputHandler;
use Runtime\Router\Route\ILoadableRoute;
@ -224,6 +225,16 @@ class Request
return $this->inputHandler;
}
/**
* Get env variable
* @param $key
* @return string
*/
public function getEnv($key)
{
return Env::get($key);
}
/**
* Is format accepted
*