From d5a9cf4d759daedc1a767219b6ccb504c763c0f0 Mon Sep 17 00:00:00 2001 From: thomabx <49051586+thomabx@users.noreply.github.com> Date: Sun, 23 Feb 2020 10:58:24 -0800 Subject: [PATCH] Check indexNumber exist for episode --- components/tvshows/details-list.brs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/components/tvshows/details-list.brs b/components/tvshows/details-list.brs index 839b857c..3b06a135 100644 --- a/components/tvshows/details-list.brs +++ b/components/tvshows/details-list.brs @@ -6,7 +6,12 @@ end sub function itemContentChanged() as void item = m.top.itemContent itemData = item.json - m.top.findNode("title").text = itemData.indexNumber.toStr() + ". " + item.title + if itemData.indexNumber <> invalid then + indexNumber = itemData.indexNumber.toStr() + ". " + else + indexNumber = "" + end if + m.top.findNode("title").text = indexNumber + item.title m.top.findNode("poster").uri = item.posterURL m.top.findNode("overview").text = item.overview