Skip to content

Commit

Permalink
bugfixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Marc André Audet committed Jun 7, 2017
1 parent 10269b7 commit e56aa79
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions src/Core.php
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ public static function initConfig(?string $json_config_file = null) : void
*
* @param ProviderInterface $provider
*/
public static function register(ProviderInterface $provider)
public static function register(ProviderInterface $provider) : void
{
$provider->register();
}
Expand Down Expand Up @@ -239,7 +239,7 @@ public static function getLibrary(string $name)
* @param string $name The path name
* @param string $i_name The class name
*/
public static function injectLibrary(string $name, string $i_name)
public static function injectLibrary(string $name, string $i_name) : void
{
self::$injected_libraries[$name] = $i_name;
}
Expand All @@ -251,9 +251,9 @@ public static function injectLibrary(string $name, string $i_name)
*
* @param string $name The path name
*
* @return object
* @return Controller
*/
public static function getController(string $name)
public static function getController(string $name) : Controller
{
if (is_object(self::$controllers[$name])) {
return self::$controllers[$name];
Expand All @@ -274,7 +274,7 @@ public static function getController(string $name)
* @param string $name The path name
* @param string $i_name The class name
*/
public static function injectController(string $name, string $i_name)
public static function injectController(string $name, string $i_name) : void
{
self::$injected_controllers[$name] = $i_name;
}
Expand All @@ -288,9 +288,9 @@ public static function injectController(string $name, string $i_name)
* @param string $name The path name
* @param string $application_path The sub-folder within the module
*
* @return object
* @return string
*/
public static function getPath(string $name, string $application_path)
public static function getPath(string $name, string $application_path) : string
{
$path = explode('/', $name);

Expand All @@ -300,7 +300,7 @@ public static function getPath(string $name, string $application_path)
$i_name = '\Application\\' . $path[0] . 'Module\\' . $application_path . '\\' . implode('\\', array_slice($path, 1));
}

return new $i_name;
return $i_name;
}

/**
Expand Down

0 comments on commit e56aa79

Please sign in to comment.