Improve search and list error messages

This commit is contained in:
Zed 2021-12-30 23:47:31 +01:00
commit 1ce6ff2b2f
2 changed files with 19 additions and 13 deletions

View file

@ -9,8 +9,8 @@ import ../views/[general, timeline, list]
export getListTimeline, getGraphList
template respList*(list, timeline, title, vnode: typed) =
if list.id.len == 0:
resp Http404, showError("List \"" & @"id" & "\" not found", cfg)
if list.id.len == 0 or list.name.len == 0:
resp Http404, showError("List " & @"id" & " not found", cfg)
let
html = renderList(vnode, timeline.query, list)