Merge branch 'main' into 26Mar

This commit is contained in:
H Lohaus 2025-03-26 21:42:29 +01:00 committed by GitHub
commit d2966d14ce
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 17 additions and 3 deletions

View file

@ -373,7 +373,7 @@ class Backend_Api(Api):
return jsonify({"error": {"message": "Not found"}}), 404
if (request.args.get("random", False)):
return redirect(f"/media/{random.choice(match_files)}"), 302
return redirect(f"/media/{match_files[int(request.args.get("skip", 0))]}"), 302
return redirect(f"/media/{match_files[int(request.args.get('skip', 0))]}", 302)
@app.route('/backend-api/v2/upload_cookies', methods=['POST'])
def upload_cookies():
@ -457,4 +457,4 @@ class Backend_Api(Api):
Returns:
str: A JSON formatted string.
"""
return json.dumps(super()._format_json(response_type, content, **kwargs)) + "\n"
return json.dumps(super()._format_json(response_type, content, **kwargs)) + "\n"