From 44e8595b418b077051330947655d09631aba7fa3 Mon Sep 17 00:00:00 2001 From: Tim Wundenberg Date: Thu, 12 Sep 2024 18:08:10 +0200 Subject: [PATCH] fix: only use umami in prod and remove UNIQUE modifier --- migration/004_user_tokens.up.sql | 2 +- template/layout.templ | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/migration/004_user_tokens.up.sql b/migration/004_user_tokens.up.sql index 47fcd6d..98d3f19 100644 --- a/migration/004_user_tokens.up.sql +++ b/migration/004_user_tokens.up.sql @@ -1,7 +1,7 @@ -- E.G. email-verifications, password-resets, unsubscribe-from-newsletter etc. CREATE TABLE user_token ( - user_uuid TEXT NOT NULL UNIQUE, + user_uuid TEXT NOT NULL, type TEXT NOT NULL, token TEXT NOT NULL UNIQUE PRIMARY KEY, diff --git a/template/layout.templ b/template/layout.templ index f118a81..7949a66 100644 --- a/template/layout.templ +++ b/template/layout.templ @@ -1,5 +1,7 @@ package template +import "me-fit/utils" + templ Layout(slot templ.Component, user templ.Component) { @@ -9,7 +11,9 @@ templ Layout(slot templ.Component, user templ.Component) { - + if utils.Environment == "prod" { + + }