Remove annoying error message

This commit is contained in:
Alex 2020-02-14 22:40:44 +01:00
parent 9bfd7f8d51
commit d78ce5309a
2 changed files with 4 additions and 6 deletions

View file

@ -12,7 +12,7 @@ job "guichet" {
task "server" {
driver = "docker"
config {
image = "lxpz/guichet_amd64:7"
image = "lxpz/guichet_amd64:8"
readonly_rootfs = true
port_map {
web_port = 9991

View file

@ -223,14 +223,12 @@ func handleInviteSendCode(w http.ResponseWriter, r *http.Request) {
r.ParseForm()
choice := strings.Join(r.Form["choice"], "")
if choice != "display" && choice != "send" {
http.Error(w, "Invalid entry", http.StatusBadRequest)
return
}
sendto := strings.Join(r.Form["sendto"], "")
if choice == "display" || choice == "send" {
trySendCode(login, choice, sendto, data)
}
}
templateInviteSendCode.Execute(w, data)
}