From 79b376a659a1d58db01f60ad049110363fbf15fc Mon Sep 17 00:00:00 2001 From: Andinus Date: Fri, 27 Mar 2020 22:20:25 +0530 Subject: Add version number --- handler/web/page.go | 1 + handler/web/register.go | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) (limited to 'handler') diff --git a/handler/web/page.go b/handler/web/page.go index cf96395..647984d 100644 --- a/handler/web/page.go +++ b/handler/web/page.go @@ -9,4 +9,5 @@ type Page struct { Error []string Success []string Notice []string + Version string } diff --git a/handler/web/register.go b/handler/web/register.go index 232768e..1e76af2 100644 --- a/handler/web/register.go +++ b/handler/web/register.go @@ -8,12 +8,13 @@ import ( "strings" "tildegit.org/andinus/perseus/auth" + "tildegit.org/andinus/perseus/core" "tildegit.org/andinus/perseus/storage/sqlite3" ) // HandleRegister handles /register pages. func HandleRegister(w http.ResponseWriter, r *http.Request, db *sqlite3.DB) { - p := Page{} + p := Page{Version: core.Version()} p.Notice = []string{ "Only [a-z] & [0-9] allowed for username", "Password length must be greater than 8 characters", -- cgit 1.4.1-2-gfad0