From 806b171ef59d1ebe6a9a6c663f47aad33f8ed580 Mon Sep 17 00:00:00 2001 From: Lucas Laurent Date: Fri, 11 Oct 2024 16:11:36 +0200 Subject: [PATCH] Fix comments php-doc for Setting --- .../core/classes/setting/Setting.class.php | 25 ++++++++++--------- 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/packages/core/classes/setting/Setting.class.php b/packages/core/classes/setting/Setting.class.php index 32cbe756e..9ee25230b 100644 --- a/packages/core/classes/setting/Setting.class.php +++ b/packages/core/classes/setting/Setting.class.php @@ -182,12 +182,12 @@ public function getUnique() { /** * Retrieve the value of a given setting. * - * @param $package Package to which the setting relates to. - * @param $section Specific section within the package. - * @param $code Unique code of the setting within the given package and section. - * @param $default (optional) Default value to return if setting is not found. - * @param $selector (optional) Retrieve the specific value assigned to a given user. - * @param $lang (optional) Lang in which to retrieve the value (for multilang settings). + * @param string $package Package to which the setting relates to. + * @param string $section Specific section within the package. + * @param string $code Unique code of the setting within the given package and section. + * @param mixed $default (optional) Default value to return if setting is not found. + * @param array $selector (optional) Retrieve the specific value assigned to a given user. + * @param string|null $lang (optional) Lang in which to retrieve the value (for multilang settings). * * @return mixed Returns the value of the target setting or null if the setting parameter is not found. The type of the returned var depends on the setting's `type` field. */ @@ -255,15 +255,16 @@ public static function get_value(string $package, string $section, string $code, /** * Update the value of a given setting. * - * @param $package Package to which the setting relates to. - * @param $section Specific section within the package. - * @param $code Unique code of the setting within the given package and section. - * @param $value The new value that has to be assigned to the setting. - * @param $selector (optional) Target the specific value assigned to a given user. + * @param string $package Package to which the setting relates to. + * @param string $section Specific section within the package. + * @param string $code Unique code of the setting within the given package and section. + * @param mixed $value The new value that has to be assigned to the setting. + * @param array $selector (optional) Target the specific value assigned to a given user. + * @param string|null $lang (optional) Lang in which to retrieve the value (for multilang settings). * * @return void */ - public static function set_value(string $package, string $section, string $code, $value, array $selector=[], $lang=null) { + public static function set_value(string $package, string $section, string $code, $value, array $selector=[], string $lang=null) { $providers = \eQual::inject(['orm']); $om = $providers['orm'];