From ae4cec37e90ecc332cb1e7985e8a471c8efe385b Mon Sep 17 00:00:00 2001 From: Arda Serdar Pektezol <1669855+pektezol@users.noreply.github.com> Date: Sun, 24 Sep 2023 01:56:28 +0300 Subject: feat: improved steam authentication (#57) Former-commit-id: 2119371693f5a64bdaf5abfc6c1a3c66a3191320 --- backend/handlers/login.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'backend') diff --git a/backend/handlers/login.go b/backend/handlers/login.go index dc6e4a5..b956c3c 100644 --- a/backend/handlers/login.go +++ b/backend/handlers/login.go @@ -12,7 +12,7 @@ import ( "github.com/golang-jwt/jwt/v4" "github.com/pektezol/leastportalshub/backend/database" "github.com/pektezol/leastportalshub/backend/models" - "github.com/solovev/steam_go" + "github.com/pektezol/steam_go" ) type LoginResponse struct { @@ -28,14 +28,14 @@ type LoginResponse struct { // @Success 200 {object} models.Response{data=LoginResponse} // @Router /login [get] func Login(c *gin.Context) { - openID := steam_go.NewOpenId(c.Request) + openID := steam_go.NewOpenID(c.Request) switch openID.Mode() { case "": c.Redirect(http.StatusMovedPermanently, openID.AuthUrl()) case "cancel": c.Redirect(http.StatusMovedPermanently, "/") default: - steamID, err := openID.ValidateAndGetId() + steamID, err := openID.ValidateAndGetID() if err != nil { CreateLog(steamID, LogTypeUser, LogDescriptionUserLoginFailValidate) c.JSON(http.StatusOK, models.ErrorResponse(err.Error())) -- cgit v1.2.3