Преглед на файлове

Fix warning with icons (#4390)

Fix warning in cases when the user context is not yet available, for instance during install
Fix regression from https://github.com/FreshRSS/FreshRSS/pull/4353
Alexandre Alapetite преди 4 години
родител
ревизия
15cdb60ba0
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      app/Models/Themes.php

+ 1 - 1
app/Models/Themes.php

@@ -128,7 +128,7 @@ class FreshRSS_Themes extends Minz_Model {
 			return Minz_Url::display($url);
 		}
 
-		if (FreshRSS_Context::$user_conf->icons_as_emojis) {
+		if (FreshRSS_Context::$user_conf && FreshRSS_Context::$user_conf->icons_as_emojis) {
 			return '<span class="icon">' . $alt . '</span>';
 		}