1
0
mirror of https://github.com/zedeus/nitter.git synced 2025-12-05 19:45:36 -05:00

Add optional cookie session fields

This commit is contained in:
Zed
2025-11-16 05:03:01 +01:00
parent 3768762fca
commit 6fe850b2c6
2 changed files with 4 additions and 1 deletions

View File

@@ -17,9 +17,10 @@ proc parseSession*(raw: string): Session =
oauthSecret: session.oauthTokenSecret
)
of "cookie":
let id = if session.id.len > 0: parseBiggestInt(session.id) else: 0
result = Session(
kind: SessionKind.cookie,
id: 999,
id: id,
authToken: session.authToken,
ct0: session.ct0
)

View File

@@ -1,6 +1,8 @@
type
RawSession* = object
kind*: string
username*: string
id*: string
oauthToken*: string
oauthTokenSecret*: string
authToken*: string