public function loadConfig()
{
// check if we can load the config file
$configClass = 'Backend\\Modules\\' . $this->getModule() . '\\Config';
if ($this->getModule() == 'Core') {
$configClass = 'Backend\\Core\\Config';
}
// validate if class exists (aka has correct name)
if (!class_exists($configClass)) {
throw new Exception('The config file ' . $configClass . ' could not be found.');
}
// create config-object, the constructor will do some magic
$this->config = new $configClass($this->getKernel(), $this->getModule());
}