parent
397471f8f4
commit
fddf1d510a
|
@ -44,3 +44,10 @@ proc createPrefRouter*(cfg: Config) =
|
|||
cache(prefs)
|
||||
savePrefs()
|
||||
redirect(refPath())
|
||||
|
||||
before:
|
||||
if @"theme".len > 0:
|
||||
var prefs = cookiePrefs()
|
||||
prefs.theme = @"theme".capitalizeAscii.replace("_", " ")
|
||||
cache(prefs)
|
||||
savePrefs()
|
||||
|
|
|
@ -47,8 +47,7 @@ proc fetchMultiTimeline*(names: seq[string]; after, agent: string; query: Query;
|
|||
return await getSearch[Tweet](q, after, agent, media)
|
||||
|
||||
proc get*(req: Request; key: string): string =
|
||||
if key in params(req): params(req)[key]
|
||||
else: ""
|
||||
params(req).getOrDefault(key)
|
||||
|
||||
proc showTimeline*(request: Request; query: Query; cfg: Config; rss: string): Future[string] {.async.} =
|
||||
let
|
||||
|
|
Loading…
Reference in New Issue