UrloMythus commited on
Commit
46eb9bf
·
1 Parent(s): 9222ffc
Files changed (1) hide show
  1. run.py +6 -21
run.py CHANGED
@@ -185,27 +185,12 @@ def addon_stream(type, id):
185
  return respond_with(streams)
186
 
187
  @app.route('/meta/<type>/<id>.json')
188
- def addon_meta(type, id):
189
- if type not in MANIFEST['types']:
190
- abort(404)
191
-
192
- meta = {}
193
- for stream_id in STREAMS.get(type, {}):
194
- if stream_id == id:
195
- item = STREAMS[type][stream_id][0] # Assuming there's at least one item
196
- meta = {
197
- "id": stream_id,
198
- "type": type,
199
- "name": item['title'],
200
- "poster": item.get('poster', "https://via.placeholder.com/150"),
201
- "background": item.get('background', "https://via.placeholder.com/800x450")
202
- }
203
- break
204
-
205
- if not meta:
206
- abort(404)
207
-
208
- return respond_with({"meta": meta})
209
 
210
  if __name__ == '__main__':
211
  app.run(host=HOST, port=PORT)
 
185
  return respond_with(streams)
186
 
187
  @app.route('/meta/<type>/<id>.json')
188
+ def meta(type, id):
189
+ return respond_with({"meta": {
190
+ "id": id,
191
+ "type": type,
192
+ "name": "Whatever Channel"
193
+ }})
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
194
 
195
  if __name__ == '__main__':
196
  app.run(host=HOST, port=PORT)