Spaces:
Runtime error
Runtime error
Commit
•
8d28f54
1
Parent(s):
65dda73
upgrade to 10 minutes
Browse files
src/core/readPostFiles.mts
CHANGED
@@ -10,8 +10,8 @@ export const readPostFiles = async (postDirFilePath: string, appId?: string, lim
|
|
10 |
|
11 |
const now = Date.now()
|
12 |
|
13 |
-
if (cache[postDirFilePath] && (now - cache[postDirFilePath].timestamp) < (
|
14 |
-
// return cached data if it's less than
|
15 |
return cache[postDirFilePath].files
|
16 |
}
|
17 |
|
|
|
10 |
|
11 |
const now = Date.now()
|
12 |
|
13 |
+
if (cache[postDirFilePath] && (now - cache[postDirFilePath].timestamp) < (10 * 60 * 1000)) {
|
14 |
+
// return cached data if it's less than 10 minutes old
|
15 |
return cache[postDirFilePath].files
|
16 |
}
|
17 |
|