cosmetic (type hint)

This commit is contained in:
Jean-Christian Paul Denis 2023-03-16 22:58:06 +01:00
parent a9fe007b0f
commit 783514eb44
Signed by: JcDenis
GPG Key ID: 1B5B8C5B90B6C951
4 changed files with 8 additions and 8 deletions

View File

@ -57,7 +57,7 @@ class My
/**
* List of possible home tab of the plugin
*/
public static function startPageCombo()
public static function startPageCombo(): array
{
return [
__('Plugins') => 'plugin',

View File

@ -44,7 +44,7 @@ class TranslaterLang
* @param string $key The lang property key
* @return mixed The lang property value or null
*/
public function get(string $key)
public function get(string $key): mixed
{
return array_key_exists($key, $this->prop) ? $this->prop[$key] : null;
}
@ -52,7 +52,7 @@ class TranslaterLang
/**
* Magic get
*/
public function __get($key)
public function __get(string $key): mixed
{
return $this->get($key);
}

View File

@ -54,7 +54,7 @@ class TranslaterModule
* @param string $key The module property key
* @return mixed The module property value or null
*/
public function get(string $key)
public function get(string $key): mixed
{
return array_key_exists($key, $this->prop) ? $this->prop[$key] : null;
}
@ -62,7 +62,7 @@ class TranslaterModule
/**
* Magic get
*/
public function __get($key)
public function __get(string $key): mixed
{
return $this->get($key);
}
@ -73,9 +73,9 @@ class TranslaterModule
* Find backup folder of a module
*
* @param boolean $throw Silently failed
* @return mixed The backup folder directory or false
* @return string|false The backup folder directory or false
*/
public function getBackupRoot(bool $throw = false)
public function getBackupRoot(bool $throw = false): string|false
{
$dir = false;
switch ($this->translater->backup_folder) {

View File

@ -16,7 +16,7 @@ namespace Dotclear\Plugin\translater;
class Uninstall
{
protected static $init = false;
protected static bool $init = false;
public static function init(): bool
{