fixed bug that caused some retweets to be rendered as truncated tweets starting with the text "RT @"
This commit is contained in:
parent
efdedd3619
commit
0f3203e903
1 changed files with 5 additions and 2 deletions
|
@ -230,8 +230,11 @@ proc parseTweet(js: JsonNode; jsCard: JsonNode = newJNull()): Tweet =
|
|||
# graphql
|
||||
with rt, js{"retweeted_status_result", "result"}:
|
||||
# needed due to weird edgecase where the actual tweet data isn't included
|
||||
if "legacy" in rt:
|
||||
result.retweet = some parseGraphTweet(rt)
|
||||
var rt_tweet = rt
|
||||
if "tweet" in rt:
|
||||
rt_tweet = rt{"tweet"}
|
||||
if "legacy" in rt_tweet:
|
||||
result.retweet = some parseGraphTweet(rt_tweet)
|
||||
return
|
||||
|
||||
if jsCard.kind != JNull:
|
||||
|
|
Loading…
Reference in a new issue