diff options
author | 2022-12-01 21:37:09 -0800 | |
---|---|---|
committer | 2022-12-01 21:37:09 -0800 | |
commit | 8cf1707cd3192814b5eb3ff99b175e211d6b1779 (patch) | |
tree | f993fa143acc385f47cb13b452e17369234106a4 /src/bun.js/api/filesystem_router.zig | |
parent | 9f4d7690ace86048abad38cfaf51eb99e944449b (diff) | |
download | bun-8cf1707cd3192814b5eb3ff99b175e211d6b1779.tar.gz bun-8cf1707cd3192814b5eb3ff99b175e211d6b1779.tar.zst bun-8cf1707cd3192814b5eb3ff99b175e211d6b1779.zip |
[bun bun] Fix crash in canary
Diffstat (limited to 'src/bun.js/api/filesystem_router.zig')
-rw-r--r-- | src/bun.js/api/filesystem_router.zig | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/bun.js/api/filesystem_router.zig b/src/bun.js/api/filesystem_router.zig index d1cec699e..41209f867 100644 --- a/src/bun.js/api/filesystem_router.zig +++ b/src/bun.js/api/filesystem_router.zig @@ -258,7 +258,7 @@ pub const FileSystemRouter = struct { .extensions = if (extensions.items.len > 0) extensions.items else default_extensions, .asset_prefix_path = asset_prefix_slice.slice(), }) catch unreachable; - router.loadRoutes(&log, root_dir_info, Resolver, &vm.bundler.resolver) catch { + router.loadRoutes(&log, root_dir_info, Resolver, &vm.bundler.resolver, router.config.dir) catch { globalThis.throwValue(log.toJS(globalThis, globalThis.allocator(), "loading routes")); origin_str.deinit(); arena.deinit(); @@ -324,7 +324,7 @@ pub const FileSystemRouter = struct { .extensions = allocator.dupe(string, this.router.config.extensions) catch unreachable, .asset_prefix_path = this.router.config.asset_prefix_path, }) catch unreachable; - router.loadRoutes(&log, root_dir_info, Resolver, &vm.bundler.resolver) catch { + router.loadRoutes(&log, root_dir_info, Resolver, &vm.bundler.resolver, router.config.dir) catch { globalThis.throwValue(log.toJS(globalThis, globalThis.allocator(), "loading routes")); arena.deinit(); |