aboutsummaryrefslogtreecommitdiff
path: root/backend/router.go
diff options
context:
space:
mode:
Diffstat (limited to 'backend/router.go')
-rw-r--r--backend/router.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/backend/router.go b/backend/router.go
index 48ffe0a..6143a3f 100644
--- a/backend/router.go
+++ b/backend/router.go
@@ -135,7 +135,8 @@ func NewRouter(debug bool, cfg *Config, db *sql.DB, assets fs.FS) *chi.Mux {
return
}
logger := GetLogger(ctx)
- if ctx.Value(loginKey).(bool) {
+ debug := ctx.Value(debugKey).(bool)
+ if ctx.Value(loginKey).(bool) && !debug {
logger.Debug("not updating stats because user is admin logged")
return
}