From b977b10cb9c110508af21009f6f017abb3769e0a Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Mon, 6 May 2024 15:08:57 +0000 Subject: [PATCH] Avoid image container if there is no image --- src/webui/static/app/dvr.js | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/webui/static/app/dvr.js b/src/webui/static/app/dvr.js index d12094fe1..12f412d18 100644 --- a/src/webui/static/app/dvr.js +++ b/src/webui/static/app/dvr.js @@ -97,13 +97,13 @@ tvheadend.dvrDetails = function(grid, index) { content += '
'; } // If we have no image then use fanart image instead. - content += '
'; - if (event.image != null && event.image.length > 0) { - content += ''; - } else if (event.fanart_image != null && event.fanart_image.length > 0) { - content += ''; - } - content += '
'; + var eventimg = ''; + if (event.image != null && event.image.length > 0) + eventimg = event.image; + else if (event.fanart_image != null && event.fanart_image.length > 0) + eventimg = event.fanart_image; + if (eventimg) + content += '
'; content += '
'; if (event.disp_summary && (!event.disp_subtitle || event.disp_subtitle != event.disp_summary)) -- 2.47.3