public function __construct(array $fromArray = array())
{
$configFile = realpath(__DIR__ . '/../../config/config.php');
// Load configuration
if (!file_exists($configFile)) {
throw new \FileNotFoundException("Can not load the config file!");
} else {
$builtIn = (require $configFile);
// If we provide an array of configurations we merge
// them to our default values
if (!empty($fromArray)) {
$this->configs = array_merge($builtIn, $fromArray);
} else {
$this->configs = $builtIn;
}
}
}