Massive refactor!
This commit is contained in:
@@ -4,7 +4,8 @@ import (
|
||||
"log"
|
||||
"net/http"
|
||||
"runtime/debug"
|
||||
"synlotto-website/helpers"
|
||||
|
||||
templateHelpers "synlotto-website/helpers/template"
|
||||
)
|
||||
|
||||
func Recover(next http.Handler) http.Handler {
|
||||
@@ -13,7 +14,7 @@ func Recover(next http.Handler) http.Handler {
|
||||
if rec := recover(); rec != nil {
|
||||
log.Printf("🔥 Recovered from panic: %v\n%s", rec, debug.Stack())
|
||||
|
||||
helpers.RenderError(w, r, http.StatusInternalServerError)
|
||||
templateHelpers.RenderError(w, r, http.StatusInternalServerError)
|
||||
}
|
||||
}()
|
||||
next.ServeHTTP(w, r)
|
||||
|
||||
Reference in New Issue
Block a user