mirror of
https://codeberg.org/ashley/poke.git
synced 2024-11-17 01:14:38 -05:00
lol
This commit is contained in:
parent
5deb6e3780
commit
7c5f28552f
1 changed files with 3 additions and 2 deletions
|
@ -46,7 +46,7 @@ app.use(function (req, res, next) {
|
|||
next();
|
||||
});
|
||||
|
||||
app.use(function (req, res, next) {
|
||||
app.use(function (_req, res, next) {
|
||||
res.header("Access-Control-Allow-Origin", "*");
|
||||
res.setHeader("Cache-Control", "public, max-age=232337763"); // cache header
|
||||
res.setHeader("poketube-cacher", "PROXY_FILES");
|
||||
|
@ -60,6 +60,7 @@ app.use(function (req, res, next) {
|
|||
*/
|
||||
const proxy = async (req, res) => {
|
||||
const { fetch } = await import("undici")
|
||||
res.setHeader("Cache-Control", "public, max-age=232337763"); // cache header
|
||||
|
||||
try {
|
||||
let url;
|
||||
|
@ -99,7 +100,7 @@ app.get("/", (req, res) => {
|
|||
status: "200",
|
||||
version: "1.1.0",
|
||||
URL_WHITELIST,
|
||||
cache: "max-age-1848",
|
||||
cache: "max-age-232337763",
|
||||
};
|
||||
|
||||
res.json(json);
|
||||
|
|
Loading…
Reference in a new issue