14 lines
694 B
JavaScript
Raw Normal View History

const fs = require("fs");
const { nextLinkCheck, nextRssRefresh, get_last_downloaded } = require('.././utils')
module.exports = function (app) {
app.get("/", (req, res) => {
2022-10-26 10:15:08 +01:00
showListLength = JSON.parse(fs.readFileSync('shows.json')).length
2023-01-24 12:04:14 +00:00
feedCacheLength = JSON.parse(fs.readFileSync('./cache/feedCache.json')).length
retryCacheLength = JSON.parse(fs.readFileSync('./cache/retryCache.json')).length
2022-10-26 10:15:08 +01:00
rssTime = nextRssRefresh()
linkCheck = nextLinkCheck()
res.render("index", { title: "Home", showListLength: showListLength, version: global.version, rssTime: rssTime, linkCheck: linkCheck, lastDownloaded: get_last_downloaded() });
});
}