diff --git a/apps/epg/tasks.py b/apps/epg/tasks.py index 0d05552f..a0a5f42e 100644 --- a/apps/epg/tasks.py +++ b/apps/epg/tasks.py @@ -114,7 +114,7 @@ def _open_xmltv_file(file_path: str): return f # Insert the DOCTYPE after the XML declaration if one is present. - stripped = start.lstrip() + stripped = start.lstrip(b'\xef\xbb\xbf').lstrip() if stripped.startswith(b'') if decl_end >= 0: