You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

17 lines
332 B
JavaScript

export default {
async fetch(req, _env) {
let url = req.url;
let iSlash = url.indexOf('/',11);
let nUrl = url.substring(iSlash+1);
1 year ago
return await goUrl(req, nUrl);
}
}
1 year ago
async function goUrl(request, url) {
let fp = {
method: request.method,
headers: request.headers
1 year ago
};
return await fetch(url, fp);
}