Skip to content
Snippets Groups Projects
Commit 84f5a1c2 authored by David Trattnig's avatar David Trattnig
Browse files

fix: _str_ handling for empty show

parent 34317e34
No related branches found
No related tags found
1 merge request!35ORM-less scheduling
...@@ -376,7 +376,10 @@ class Timeslot: ...@@ -376,7 +376,10 @@ class Timeslot:
""" """
start = SimpleUtil.fmt_time(self.start) start = SimpleUtil.fmt_time(self.start)
end = SimpleUtil.fmt_time(self.end) end = SimpleUtil.fmt_time(self.end)
return f"ID#{self.id}: {start} - {end} [Show#{self.show.id}: {self.show.name}]" s = f"ID#{self.id}: {start} - {end}"
if self.show:
s += f" [Show#{self.show.id}: {self.show.name}]"
return s
class PlaylistType(enum.Enum): class PlaylistType(enum.Enum):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment