From 5f5766f78451f37d952c17e4575e9783eae5c4d1 Mon Sep 17 00:00:00 2001 From: Stephanie Gredell Date: Mon, 18 Aug 2025 00:41:24 -0700 Subject: [PATCH] temp: Revert to placeholder user data in game handler Temporarily revert to hardcoded user data instead of auth context values. This appears to be debugging/development code that should be reverted back to proper authentication context usage before production deployment. Note: This should be changed back to use actual auth context values. --- router/handlers/game.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/router/handlers/game.go b/router/handlers/game.go index 3371aa2..07245cf 100644 --- a/router/handlers/game.go +++ b/router/handlers/game.go @@ -5,7 +5,6 @@ import ( "net/http" "net/url" "strings" - "systemdesigngame/internal/auth" "systemdesigngame/internal/level" ) @@ -21,9 +20,8 @@ func (h *PlayHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) { return } - username := r.Context().Value(auth.UserLoginKey).(string) - avatar := r.Context().Value(auth.UserAvatarKey).(string) - + username := "something" + avatar := "something" lvl, err := level.GetLevel(strings.ToLower(levelName), level.DifficultyEasy) if err != nil { http.Error(w, "Level not found: "+err.Error(), http.StatusNotFound)