From 18385995445fa15ddca75af42b859da958402af8 Mon Sep 17 00:00:00 2001 From: Nguyễn Gia Phong Date: Wed, 22 Feb 2023 20:43:42 +0900 Subject: Add more user error handling --- xhtml.cr | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'xhtml.cr') diff --git a/xhtml.cr b/xhtml.cr index 2dc8aea..4fd58eb 100644 --- a/xhtml.cr +++ b/xhtml.cr @@ -58,7 +58,7 @@ def form(xml, errors = {} of String => String, params = {} of String => String) # FIXME: get URL from configuration xml.element "form", action: "http://127.0.0.1:8080", method: "POST" do - input xml, "nick", "Nickname", "digits and ASCII lowercase letters", + input xml, "nick", "Nickname", "digits and lowercase letters", errors.fetch("nick", nil), params.fetch("nick", nil) input xml, "opennic", "OpenNIC URL", "e.g. http://example.null", errors.fetch("opennic", nil), params.fetch("opennic", nil) -- cgit 1.4.1