Procházet zdrojové kódy

Fix "Show this thread" for pinned threads

Zed před 3 roky
rodič
revize
b1ef505cff
1 změnil soubory, kde provedl 4 přidání a 0 odebrání
  1. 4 0
      src/parser.nim

+ 4 - 0
src/parser.nim

@@ -206,6 +206,10 @@ proc parseTweet(js: JsonNode): Tweet =
     )
     )
   )
   )
 
 
+  # fix for pinned threads
+  if result.hasThread and result.threadId == 0:
+    result.threadId = js{"self_thread", "id_str"}.getId
+
   result.expandTweetEntities(js)
   result.expandTweetEntities(js)
 
 
   if js{"is_quote_status"}.getBool:
   if js{"is_quote_status"}.getBool: