make sure date later than now will now be publish
This commit is contained in:
1 parent
9ea60c68c7
commit
d8161be401
47 files changed
+25
-11589
No files matched your search
@@ -29,7 +29,7 @@ export const getStaticPaths: GetStaticPaths = async () => {
|
||||
paths: Array(
|
||||
Math.ceil(
|
||||
dbPost.find({
|
||||
date: { $exists: true } as any
|
||||
date: { $lt: new Date().getTime() }
|
||||
}).length / 5
|
||||
) - 1
|
||||
)
|
||||
|
||||
Reference in new issue
Block a user