PHPDoc and code conventions

This commit is contained in:
Molkobain
2021-01-22 09:24:40 +01:00
parent 2ed785fb06
commit 1bb6d62c17
2 changed files with 13 additions and 6 deletions

View File

@@ -93,7 +93,7 @@ abstract class Controller
*/
public function InitFromModule()
{
$sModulePath = dirname(dirname($this->getDir()));
$sModulePath = dirname(dirname($this->GetDir()));
$this->SetModuleName(basename($sModulePath));
$this->SetViewPath($sModulePath.'/view');
try
@@ -128,7 +128,10 @@ abstract class Controller
$this->m_sModule = $sModule;
}
private function getDir()
/**
* @return string
*/
private function GetDir(): string
{
return dirname((new ReflectionClass(static::class))->getFileName());
}