const express = require("express") const router = express.Router() const gameFilesService = require("../services/gameDataService") router.get(/.*/, async (req, res) => { const fileRequest = await gameFilesService.getFile(req.baseUrl.replace("/download/", "")) return res.status(fileRequest.code).sendFile(fileRequest.path) }) module.exports = router