|
|
@@ -1,5 +1,4 @@
|
|
|
import { serve } from 'https://deno.land/std@0.168.0/http/server.ts'
|
|
|
-import { wrapHandler } from '../_shared/error-handler.ts'
|
|
|
|
|
|
const corsHeaders = {
|
|
|
'Access-Control-Allow-Origin': '*',
|
|
|
@@ -25,7 +24,7 @@ const corsHeaders = {
|
|
|
* Request and response bodies are proxied as-is.
|
|
|
*/
|
|
|
|
|
|
-serve(wrapHandler('shoprenter-proxy', async (req) => {
|
|
|
+serve(async (req) => {
|
|
|
// Handle CORS preflight
|
|
|
if (req.method === 'OPTIONS') {
|
|
|
return new Response('ok', { headers: corsHeaders })
|
|
|
@@ -155,4 +154,4 @@ serve(wrapHandler('shoprenter-proxy', async (req) => {
|
|
|
}
|
|
|
)
|
|
|
}
|
|
|
-}))
|
|
|
+})
|