This commit is contained in:
skeris 2024-04-13 01:41:30 +03:00
parent 5e668f6756
commit cdd3d30cbb

@ -6,6 +6,8 @@ import (
"penahub.gitlab.yandexcloud.net/backend/quiz/common.git/model" "penahub.gitlab.yandexcloud.net/backend/quiz/common.git/model"
"penahub.gitlab.yandexcloud.net/backend/quiz/common.git/repository/quiz" "penahub.gitlab.yandexcloud.net/backend/quiz/common.git/repository/quiz"
"time" "time"
"fmt"
"net/url"
"unicode/utf8" "unicode/utf8"
) )
@ -473,9 +475,11 @@ func (s *Service) MiniPart(ctx *fiber.Ctx) error {
return ctx.Status(fiber.StatusInternalServerError).SendString(err.Error()) return ctx.Status(fiber.StatusInternalServerError).SendString(err.Error())
} }
fmt.Println("OLOLO", string(shifr))
ctx.Cookie(&fiber.Cookie{ ctx.Cookie(&fiber.Cookie{
Name: "quizUser", Name: "quizUser",
Value: string(shifr), Value: url.QueryEscape(string(shifr)),
}) })
return ctx.Redirect(s.redirectURl, fiber.StatusFound) return ctx.Redirect(s.redirectURl, fiber.StatusFound)