|
@@ -90,10 +90,14 @@ export class SqliteStore extends Store {
|
|
ORDER BY id DESC
|
|
ORDER BY id DESC
|
|
`, [ BigInt(authorId), BigInt(olderThanId), dateToEpoch(newerThan) ]);
|
|
`, [ BigInt(authorId), BigInt(olderThanId), dateToEpoch(newerThan) ]);
|
|
|
|
|
|
- return result.map(([ tweetStr ]) => {
|
|
|
|
- const tweet = JSON.parse(tweetStr);
|
|
|
|
- return TweetSchema.parse(tweet);
|
|
|
|
- });
|
|
|
|
|
|
+ return result
|
|
|
|
+ .map(([ tweetStr ]) => {
|
|
|
|
+ const tweet = JSON.parse(tweetStr);
|
|
|
|
+ return TweetSchema.parse(tweet);
|
|
|
|
+ })
|
|
|
|
+ .filter(({ in_reply_to_user_id_str }) => {
|
|
|
|
+ return in_reply_to_user_id_str === null || in_reply_to_user_id_str === authorId;
|
|
|
|
+ });
|
|
}
|
|
}
|
|
|
|
|
|
getAuthorId(username: string): string | null {
|
|
getAuthorId(username: string): string | null {
|