Monorepo for Tangled tangled.org

appview: strings: return 404 page if string wasnt found

Signed-off-by: dusk <y.bera003.06@protonmail.com>

Changed files
+5
appview
strings
+5
appview/strings/strings.go
··· 99 99 w.WriteHeader(http.StatusInternalServerError) 100 100 return 101 101 } 102 + if len(strings) < 1 { 103 + l.Error("string not found") 104 + s.Pages.Error404(w) 105 + return 106 + } 102 107 if len(strings) != 1 { 103 108 l.Error("incorrect number of records returned", "len(strings)", len(strings)) 104 109 w.WriteHeader(http.StatusInternalServerError)