Skip to content

Commit

Permalink
Merge branch 'sprint-35' of https://github.com/Avanade/approval-system
Browse files Browse the repository at this point in the history
…into 116-refactor-approver-response-page
  • Loading branch information
iibuan committed Oct 15, 2024
2 parents c21e8a2 + 98d6792 commit 9a00979
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/goapp/routes/pages/redirect.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package routes

import (
"net/http"
"html/template"
"net/http"
)

func LoginRedirectHandler(w http.ResponseWriter, r *http.Request) {
Expand All @@ -14,6 +14,12 @@ func LoginRedirectHandler(w http.ResponseWriter, r *http.Request) {
data := map[string]interface{}{
"redirect": redirect,
}

c := http.Cookie{
Name: "auth-session",
MaxAge: -1}
http.SetCookie(w, &c)

tmpl := template.Must(template.ParseFiles("templates/loginredirect.html"))
tmpl.Execute(w, data)
}
}

0 comments on commit 9a00979

Please sign in to comment.