@@ -44,28 +44,41 @@ public static function getConfigValue(string $name, ?int $idSite = null)
4444 return static ::getRawConfigValue ($ name , $ idSite );
4545 }
4646
47+ /**
48+ * @phpstan-return ($default is null ? int|null : int)
49+ */
4750 public static function getIntegerConfigValue (string $ name , ?int $ default = null , ?int $ idSite = null ): ?int
4851 {
4952 return self ::castIntConfigValue ($ name , static ::getRawConfigValue ($ name , $ idSite ), $ default );
5053 }
5154
55+ /**
56+ * @phpstan-return ($default is null ? float|null : float)
57+ */
5258 public static function getFloatConfigValue (string $ name , ?float $ default = null , ?int $ idSite = null ): ?float
5359 {
5460 return self ::castFloatConfigValue ($ name , static ::getRawConfigValue ($ name , $ idSite ), $ default );
5561 }
5662
63+ /**
64+ * @phpstan-return ($default is null ? bool|null : bool)
65+ */
5766 public static function getBoolConfigValue (string $ name , ?bool $ default = null , ?int $ idSite = null ): ?bool
5867 {
5968 return self ::castBoolConfigValue ($ name , static ::getRawConfigValue ($ name , $ idSite ), $ default );
6069 }
6170
71+ /**
72+ * @phpstan-return ($default is null ? string|null : string)
73+ */
6274 public static function getStringConfigValue (string $ name , ?string $ default = null , ?int $ idSite = null ): ?string
6375 {
6476 return self ::castStringConfigValue ($ name , static ::getRawConfigValue ($ name , $ idSite ), $ default );
6577 }
6678
6779 /**
6880 * @return array<mixed>|null
81+ * @phpstan-return ($default is null ? array<mixed>|null : array<mixed>)
6982 */
7083 public static function getArrayConfigValue (string $ name , ?array $ default = null , ?int $ idSite = null ): ?array
7184 {
0 commit comments