mirror of
https://github.com/zedeus/nitter.git
synced 2025-12-07 20:45:36 -05:00
Refactor hostname to be a runtime option
Add a `hostname` field under Server in your conf file, see the updated nitter.conf in the repo for an example. The compile-time option (-d:hostname) is no longer used.
This commit is contained in:
@@ -8,10 +8,10 @@ import ../views/[general, timeline, list]
|
||||
|
||||
template respList*(list, timeline: typed) =
|
||||
if list.minId.len == 0:
|
||||
halt Http404, showError("List \"" & @"list" & "\" not found", cfg.title)
|
||||
halt Http404, showError("List \"" & @"list" & "\" not found", cfg)
|
||||
let html = renderList(timeline, list.query, @"name", @"list")
|
||||
let rss = "/$1/lists/$2/rss" % [@"name", @"list"]
|
||||
resp renderMain(html, request, cfg.title, rss=rss)
|
||||
resp renderMain(html, request, cfg, rss=rss)
|
||||
|
||||
proc createListRouter*(cfg: Config) =
|
||||
router list:
|
||||
|
||||
Reference in New Issue
Block a user