Skip to content

Commit

Permalink
feat: download video
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelfromyeg committed Jan 8, 2024
1 parent 3693ccd commit 1f9a404
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion bereal/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ def get_video(filename: str) -> tuple[Response, int]:
return jsonify({"error": "Unauthorized", "message": "Invalid token"}), 401

logger.debug("Serving video file %s/%s to %s...", EXPORTS_PATH, filename, phone)
return send_from_directory(EXPORTS_PATH, filename, mimetype="video/mp4"), 200
return send_from_directory(EXPORTS_PATH, filename, mimetype="video/mp4", as_attachment=True), 200


@app.route("/robots.txt")
Expand Down

0 comments on commit 1f9a404

Please sign in to comment.