mirror of
https://github.com/zedeus/nitter
synced 2026-09-05 22:59:31 +00:00
parent
23f87c115a
commit
f3d6f53f6d
4 changed files with 20 additions and 21 deletions
|
|
@ -38,10 +38,10 @@ proc getBanner(user: User): string =
|
|||
return '#' & user.profileLinkColor
|
||||
return "#161616"
|
||||
|
||||
proc parseUser*(json: string): Profile =
|
||||
proc parseUser*(json: string; username=""): Profile =
|
||||
handleErrors:
|
||||
case error.code
|
||||
of suspended: return Profile(suspended: true)
|
||||
of suspended: return Profile(username: username, suspended: true)
|
||||
of userNotFound: return
|
||||
else: echo "[error - parseUser]: ", error
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue