add env variable for interval time
This commit is contained in:
parent
333d26ada6
commit
927387ffb5
1 changed files with 1 additions and 1 deletions
2
main.js
2
main.js
|
@ -92,4 +92,4 @@ async function fetchNewPosts() {
|
||||||
|
|
||||||
fetchNewPosts();
|
fetchNewPosts();
|
||||||
// Fetch new posts every 5 minutes (adjust as needed)
|
// Fetch new posts every 5 minutes (adjust as needed)
|
||||||
setInterval(fetchNewPosts, 2 * 60 * 1000);
|
setInterval(fetchNewPosts, (process.env.INTERVAL_MINUTES ?? 5) * 60 * 1000);
|
||||||
|
|
Loading…
Reference in a new issue