1
0
mirror of https://github.com/fHDHR/fHDHR_NextPVR.git synced 2025-12-06 13:36:59 -05:00
fHDHR_NextPVR/fHDHR_web/files/device_xml.py
2020-12-20 11:13:00 -05:00

20 lines
474 B
Python

from flask import redirect, session
class Device_XML():
endpoints = ["/device.xml"]
endpoint_name = "file_device_xml"
def __init__(self, fhdhr):
self.fhdhr = fhdhr
def __call__(self, *args):
return self.get(*args)
def get(self, *args):
if self.fhdhr.config.dict["rmg"]["enabled"] and session["is_plexmediaserver"]:
return redirect("/rmg/device.xml")
else:
return redirect("/hdhr/device.xml")