Skip to content

Commit 32d9bc8

Browse files
committed
Added an array length check to prevent an error message when the number of columns is small.
Signed-off-by: Ken McGaugh <ken@mcgaugh.co.uk>
1 parent c4e56ca commit 32d9bc8

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

src/plugin/python_plugins/on_screen_version_name/on_screen_version_name.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,9 @@ def media_item_hud_data(self, media_item = None):
133133
# display_info is an array of values corresponding to the columns
134134
# of the Media List Panel in the xSTUDIO UI (the columns are fully
135135
# user-configurable, by the way)
136-
return media_item.display_info[idx]
136+
return media_item.display_info[idx] \
137+
if idx < len(media_item.display_info) \
138+
else ""
137139
else:
138140
return ""
139141

0 commit comments

Comments
 (0)