From e5ebcef68400c6d61cf54e870d70013ecee18d8b Mon Sep 17 00:00:00 2001 From: Harvey Tindall Date: Fri, 31 Jul 2020 13:03:36 +0100 Subject: [PATCH] Partial check for invite page, 404 handling The invite route no longer calls checkInvite, instead just chekcing the invite exists. This speeds up page loading. the 404 and invalidCode pages are now loaded when necessary. --- .../404.html | 14 +++++++------- .../invalidCode.html | 14 +++++++------- main.go | 1 + pwval.go | 2 -- views.go | 18 ++++++++++++++++-- 5 files changed, 31 insertions(+), 18 deletions(-) rename data/{currently-unused-templates => templates}/404.html (90%) rename data/{currently-unused-templates => templates}/invalidCode.html (87%) diff --git a/data/currently-unused-templates/404.html b/data/templates/404.html similarity index 90% rename from data/currently-unused-templates/404.html rename to data/templates/404.html index e50cb74..e91cd75 100644 --- a/data/currently-unused-templates/404.html +++ b/data/templates/404.html @@ -13,16 +13,16 @@ 404 - - {% if not bs5 %} + + {{ if not .bs5 }} - {% endif %} + {{ end }} - {% if bs5 %} + {{ if .bs5 }} - {% else %} + {{ else }} - {% endif %} + {{ end }}