diff --git a/classes/rssutils.php b/classes/rssutils.php index b3363954c..26e9dd033 100755 --- a/classes/rssutils.php +++ b/classes/rssutils.php @@ -633,12 +633,14 @@ class RSSUtils { $feed_obj->save(); $feed_obj->favicon_avg_color = \Colors\calculate_avg_color($favicon_cache->get_full_path($feed)); - $feed_obj->save(); + if ($feed_obj->favicon_avg_color) { + $feed_obj->save(); + } Debug::log("favicon: avg color: {$feed_obj->favicon_avg_color}", Debug::LOG_VERBOSE); } else if ($feed_obj->favicon_avg_color == 'fail') { - Debug::log("floicon failed on $feed, not trying to recalculate avg color", Debug::LOG_VERBOSE); + Debug::log("floicon failed on $feed or a suitable avg color couldn't be determined, not trying to recalculate avg color", Debug::LOG_VERBOSE); } }