optimize fetching timeline

This commit is contained in:
Vincent Cloutier 2023-07-11 23:40:52 -04:00
parent b469f95de9
commit 5ac5555bf6
2 changed files with 6 additions and 2 deletions

View file

@ -293,7 +293,12 @@ namespace BirdsiteLive.Twitter
.GetProperty("retweeted_status_result").GetProperty("result")
.GetProperty("core").GetProperty("user_result").GetProperty("result")
.GetProperty("legacy").GetProperty("screen_name").GetString();
OriginalAuthor = await _twitterUserService.GetUserAsync(OriginalAuthorUsername);
JsonElement OriginalAuthorDoc = tweet.GetProperty("content").GetProperty("content")
.GetProperty("tweetResult").GetProperty("result").GetProperty("legacy")
.GetProperty("retweeted_status_result").GetProperty("result")
.GetProperty("core").GetProperty("user_result").GetProperty("result");
OriginalAuthor = _twitterUserService.Extract(OriginalAuthorDoc);
//OriginalAuthor = await _twitterUserService.GetUserAsync(OriginalAuthorUsername);
retweetId = Int64.Parse(tweet.GetProperty("content").GetProperty("content")
.GetProperty("tweetResult").GetProperty("result").GetProperty("legacy")
.GetProperty("retweeted_status_result").GetProperty("result")

View file

@ -52,7 +52,6 @@ namespace BirdsiteLive.ActivityPub.Tests
Assert.IsTrue(tweets.Length > 5);
}
[Ignore]
[TestMethod]
public async Task TimelineGrant()
{