see #16
This commit is contained in:
1 parent
eb7920f1c0
commit
d9c62e2428
2 files changed
+6
-2
No files matched your search
@@ -239,6 +239,10 @@ func (i *Info) serveListing(w http.ResponseWriter, r *http.Request, c *config.Co
|
||||
page.Minimal = true
|
||||
}
|
||||
|
||||
if strings.Contains(r.Header.Get("Accept"), "application/json") {
|
||||
return page.PrintAsJSON(w)
|
||||
}
|
||||
|
||||
return page.PrintAsHTML(w, "listing")
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user