Merge pull request 'dev' (#53) from dev into master
All checks were successful
Deploy application with Docker / build_and_deploy (push) Successful in 42s
All checks were successful
Deploy application with Docker / build_and_deploy (push) Successful in 42s
Reviewed-on: #53
This commit is contained in:
commit
119e87ba49
@ -26,12 +26,14 @@ func (s *Server) HomePageHandler(ctx *gin.Context) {
|
|||||||
loggedIn := domain.IsLoggedIn(ctx)
|
loggedIn := domain.IsLoggedIn(ctx)
|
||||||
|
|
||||||
// Ensure user is logged in with a valid account
|
// Ensure user is logged in with a valid account
|
||||||
|
if loggedIn {
|
||||||
if user := s.deps.UserService.GetAuthenicatedUser(ctx); user == nil {
|
if user := s.deps.UserService.GetAuthenicatedUser(ctx); user == nil {
|
||||||
// Log (stale) user out
|
// Log (stale) user out
|
||||||
s.SetCookie(ctx, "jwt_token", "", -1)
|
s.SetCookie(ctx, "jwt_token", "", -1)
|
||||||
s.SetCookie(ctx, "search-filters", "", -1)
|
s.SetCookie(ctx, "search-filters", "", -1)
|
||||||
loggedIn = false
|
loggedIn = false
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
var page templ.Component
|
var page templ.Component
|
||||||
if loggedIn {
|
if loggedIn {
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user