|
|
@ -47,7 +47,7 @@ async function handleEvent(event) {
|
|
|
|
if (!DEBUG) {
|
|
|
|
if (!DEBUG) {
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|
let notFoundResponse = await getAssetFromKV(event, {
|
|
|
|
let notFoundResponse = await getAssetFromKV(event, {
|
|
|
|
mapRequestToAsset: req => new Request(`${new URL(req.url).origin}/404.html`, req),
|
|
|
|
mapRequestToAsset: req => new Request(`${new URL(req.url).origin}/index.html`, req),
|
|
|
|
})
|
|
|
|
})
|
|
|
|
|
|
|
|
|
|
|
|
return new Response(notFoundResponse.body, { ...notFoundResponse, status: 404 })
|
|
|
|
return new Response(notFoundResponse.body, { ...notFoundResponse, status: 404 })
|
|
|
|