This commit is contained in:
bingus_violet 2024-06-10 18:30:24 -05:00
parent d13fdc8927
commit cddcb51a57

View file

@ -61,6 +61,7 @@ app.get("/cached/*", (req, res) => {
imgWait += 0.1
setTimeout(() => {
imgData = cachedImages.imgs[imgURL]
console.log(imgData)
if (imgData) {
fs.createReadStream(path.join(imgCache, imgData.file)).pipe(res)
} else {
@ -87,7 +88,7 @@ var cachedImages = JSON.parse(fs.readFileSync(cacheFile))
var constants = JSON.parse(fs.readFileSync(path.join(__dirname, "constants.json")))
var activityImages = constants.activityImages
var thumborURL = "https://thumbor-production-0e82.up.railway.app/"
var thumborURL = "https://thumbor-production-0e82.up.railway.app/unsafe"
var imgExtension = "png"
var thumborArgs = `filters:format(${imgExtension})/`