Skip to content
This repository was archived by the owner on Oct 31, 2026. It is now read-only.

Commit 78a7357

Browse files
committed
worker.js: escape slashes inside character classes for esbuild
V8 accepts unescaped / in [^/], but wrangler's bundler rejects it with 'Unterminated regular expression'. [^\/] parses everywhere.
1 parent 9b3127a commit 78a7357

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎apt-worker/worker.js‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ export default {
1313
async fetch(request, env) {
1414
const url = new URL(request.url);
1515
const m = url.pathname.match(
16-
/^\/pool\/[^/]+\/[^/]+\/(opencode2_(.+)-(\d+)_aarch64\.deb)$,
16+
/^\/pool\/[^\/]+\/[^\/]+\/(opencode2_(.+)-(\d+)_aarch64\.deb)$,
1717
);
1818
if (m) {
1919
const file = m[1];

0 commit comments

Comments
 (0)