feat: filter out scheduled post

This commit is contained in:
DIYgod 2023-07-11 11:46:49 +01:00
parent cfa2c240f8
commit 289e7b4c67
No known key found for this signature in database
1 changed files with 5 additions and 0 deletions

View File

@ -319,6 +319,11 @@ export const HomeFeed = ({ type }: { type?: FeedType }) => {
}, [] as ExpandedNote[])
.filter((post) => {
if (
new Date(post.metadata?.content?.date_published || "") >
new Date()
) {
return false
} else if (
aiFiltering &&
post.metadata?.content?.score?.number !== undefined &&
post.metadata.content.score.number <= 60