modified: app.py

This commit is contained in:
SimolZimol
2025-05-19 17:41:52 +02:00
parent d38254bc3c
commit e7aa9c2660

6
app.py
View File

@@ -78,7 +78,7 @@ def get_all_playlist_tracks(sp, playlist_id):
@app.route("/")
def home():
return render_template("login.html")
return render_template("login.html", translations=get_translations())
@app.route("/login")
def login():
@@ -109,7 +109,7 @@ def callback():
def playlists():
sp = get_spotify_client()
playlists = sp.current_user_playlists()["items"]
return render_template("playlists.html", playlists=playlists)
return render_template("playlists.html", playlists=playlists, translations=get_translations())
@app.route("/quiz/<playlist_id>")
def quiz(playlist_id):
@@ -272,7 +272,7 @@ def logout():
@app.route('/')
def index():
user = session.get('user') # Benutzerinfos aus der Session holen, falls vorhanden
return render_template('index.html', user=user)
return render_template('index.html', user=user, translations=get_translations())
@app.route("/reset_quiz/<playlist_id>")
def reset_quiz(playlist_id):