diff options
| author | 2024-09-11 17:14:53 +0200 | |
|---|---|---|
| committer | 2024-09-11 17:14:53 +0200 | |
| commit | dfac9f5813df7d4c7c812c381364c8898333f559 (patch) | |
| tree | 978496d0a8d8b0d6b5dbe836c6829296133b337c /app/Models/Themes.php | |
| parent | 31c8846791d4b5316fbc790202f79545c012f9c2 (diff) | |
PHPStan booleansInConditions (#6793)
* PHPStan booleansInConditions
* Uniformisation
Diffstat (limited to 'app/Models/Themes.php')
| -rw-r--r-- | app/Models/Themes.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/Models/Themes.php b/app/Models/Themes.php index 055db42e5..a5167c8e8 100644 --- a/app/Models/Themes.php +++ b/app/Models/Themes.php @@ -21,7 +21,7 @@ class FreshRSS_Themes extends Minz_Model { $list = []; foreach ($themes_list as $theme_dir) { $theme = self::get_infos($theme_dir); - if ($theme) { + if (is_array($theme)) { $list[$theme_dir] = $theme; } } @@ -60,7 +60,7 @@ class FreshRSS_Themes extends Minz_Model { */ public static function load(string $theme_id): array|false { $infos = self::get_infos($theme_id); - if (!$infos) { + if (empty($infos)) { if ($theme_id !== self::$defaultTheme) { //Fall-back to default theme return self::load(self::$defaultTheme); } |
