mirror of
https://github.com/zedeus/nitter
synced 2026-09-06 07:09:31 +00:00
Fix loading more tweets when last one is a retweet
This commit is contained in:
parent
2c2d2c767e
commit
8f7c61eab6
3 changed files with 6 additions and 3 deletions
|
|
@ -72,14 +72,15 @@
|
|||
#var retweets: Tweets
|
||||
#for tweet in tweets:
|
||||
#if tweet in retweets: continue
|
||||
#end if
|
||||
#if tweet.retweetBy.isSome: retweets.add tweet
|
||||
#elif tweet.retweetBy.isSome: retweets.add tweet
|
||||
#end if
|
||||
${renderTweet(tweet, "timeline-tweet")}
|
||||
#end for
|
||||
#if tweets.len > 0:
|
||||
<div class="show-more">
|
||||
<a href="/${profile.username}?after=${$tweets[^1].id}">Load older tweets</a>
|
||||
#let retweet = tweets[^1].retweetId.get("")
|
||||
#let id = if retweet.len > 0: retweet else: tweets[^1].id
|
||||
<a href="/${profile.username}?after=${$id}">Load older tweets</a>
|
||||
</div>
|
||||
#end if
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Reference in a new issue