Skip to content

Commit

Permalink
ok-3
Browse files Browse the repository at this point in the history
  • Loading branch information
aigem committed Sep 12, 2024
1 parent c7e8e0a commit aab18f1
Show file tree
Hide file tree
Showing 2 changed files with 199 additions and 139 deletions.
5 changes: 3 additions & 2 deletions src/handlers/requestHandler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,12 @@ export async function handleRequest(request: Request, env: Env, ctx: ExecutionCo
});
}

const response = await handleWebDAV(request, env.BUCKET, env.BUCKET_NAME, env); // 传递 env 参数
const response = await handleWebDAV(request, env.BUCKET, env.BUCKET_NAME);

setCORSHeaders(response, request);
return response;
} catch (error) {
logger.error("Error in request handling:", error);
return new Response("Internal Server Error", { status: 500 });
}
}
}
Loading

0 comments on commit aab18f1

Please sign in to comment.