domain updates

This commit is contained in:
James Tombleson 2024-04-14 18:38:44 -07:00
parent 22940d952c
commit f9c7032e92

View File

@ -3,6 +3,7 @@ package handlers
import ( import (
"log" "log"
"net/http" "net/http"
"templ-test/domain"
"templ-test/views/auth" "templ-test/views/auth"
"templ-test/views/home" "templ-test/views/home"
@ -25,17 +26,17 @@ func (h *Handlers) AuthLoginPost(c echo.Context) error {
} }
cookie := new(http.Cookie) cookie := new(http.Cookie)
cookie.Name = CookieToken cookie.Name = domain.CookieToken
cookie.Value = resp.Token cookie.Value = resp.Token
c.SetCookie(cookie) c.SetCookie(cookie)
cookie = new(http.Cookie) cookie = new(http.Cookie)
cookie.Name = CookieRefreshToken cookie.Name = domain.CookieRefreshToken
cookie.Value = resp.RefreshToken cookie.Value = resp.RefreshToken
c.SetCookie(cookie) c.SetCookie(cookie)
cookie = new(http.Cookie) cookie = new(http.Cookie)
cookie.Name = CookieUser cookie.Name = domain.CookieUser
cookie.Value = user cookie.Value = user
c.SetCookie(cookie) c.SetCookie(cookie)