mirror of
https://github.com/zedeus/nitter
synced 2026-09-05 22:59:31 +00:00
Find TimelineAddEntries in tweets response (#1251)
See https://github.com/zedeus/nitter/issues/1250. Sometimes the API gives us more results and the tweets are no longer at index 0.
This commit is contained in:
parent
94c83f3811
commit
e40c61a6ae
1 changed files with 35 additions and 33 deletions
|
|
@ -364,7 +364,9 @@ proc parseGraphConversation*(js: JsonNode; tweetId: string; v2=true): Conversati
|
|||
if instructions.len == 0:
|
||||
return
|
||||
|
||||
for e in instructions[0]{"entries"}:
|
||||
for i in instructions:
|
||||
if i{"__typename"}.getStr == "TimelineAddEntries":
|
||||
for e in i{"entries"}:
|
||||
let entryId = e{"entryId"}.getStr
|
||||
if entryId.startsWith("tweet"):
|
||||
with tweetResult, e{"content", contentKey, resultKey, "result"}:
|
||||
|
|
|
|||
Loading…
Reference in a new issue