permission für videos
This commit is contained in:
parent
0d023a503b
commit
2ab719774b
@ -408,8 +408,14 @@ def health():
|
||||
|
||||
|
||||
@app.route("/images/<path:filename>")
|
||||
def serve_image(filename):
|
||||
return send_from_directory("/app/images", filename)
|
||||
def images(filename):
|
||||
|
||||
# 🔒 Schutz für Videos
|
||||
if filename.startswith("videos/"):
|
||||
if not session.get("user_id"):
|
||||
return redirect(url_for("login", next=request.path))
|
||||
|
||||
return send_from_directory("images", filename)
|
||||
|
||||
|
||||
@app.route("/styles/<path:filename>")
|
||||
|
||||
BIN
app/flask-postgres/images/videos/C3 Vendor.mp4
Normal file
BIN
app/flask-postgres/images/videos/C3 Vendor.mp4
Normal file
Binary file not shown.
BIN
app/flask-postgres/images/videos/C4 Risk Mapping.mp4
Normal file
BIN
app/flask-postgres/images/videos/C4 Risk Mapping.mp4
Normal file
Binary file not shown.
BIN
app/flask-postgres/images/videos/C5 Umsetzung.mp4
Normal file
BIN
app/flask-postgres/images/videos/C5 Umsetzung.mp4
Normal file
Binary file not shown.
Loading…
Reference in New Issue
Block a user