Skip to content

Commit

Permalink
Revert "Support cors"
Browse files Browse the repository at this point in the history
This reverts commit b49dc6f.
  • Loading branch information
makoto committed Dec 1, 2023
1 parent 128bbbd commit 36f68d5
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 7 deletions.
5 changes: 1 addition & 4 deletions arb-gateway/src/worker.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,11 @@
import { Server } from '@ensdomains/ccip-read-cf-worker';
import { createCors } from 'itty-router';
import type { Router } from '@ensdomains/evm-gateway';

interface Env {
L1_PROVIDER_URL: string;
L2_PROVIDER_URL: string;
L2_ROLLUP: string;
}

const {corsify} = createCors()
let app: Router;
async function fetch(request: Request, env: Env) {
// Loading libraries dynamically as a temp work around.
Expand All @@ -34,7 +31,7 @@ async function fetch(request: Request, env: Env) {
gateway.add(server);
app = server.makeApp('/');
}
return app.handle(request).then(corsify);
return app.handle(request);
}

export default {
Expand Down
3 changes: 1 addition & 2 deletions arb-verifier/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,7 @@
"typescript": "^5.2.2"
},
"dependencies": {
"@arbitrum/nitro-contracts": "^1.1.0",
"@ensdomains/evm-verifier": "^0.1.0",
"itty-router": "^4.0.23"
"@arbitrum/nitro-contracts": "^1.1.0"
}
}
Binary file modified bun.lockb
Binary file not shown.
2 changes: 1 addition & 1 deletion evm-gateway/src/utils.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
export interface Router {
handle: (request: Request) => Promise<any>;
handle: (request: Request) => void;
}

0 comments on commit 36f68d5

Please sign in to comment.