fix: try to address issues running serverus from jsr.io
This commit is contained in:
parent
bc8b67361d
commit
dd2e98ccd9
2 changed files with 2 additions and 2 deletions
|
@ -7,7 +7,7 @@ import * as colors from '@std/fmt/colors';
|
|||
import * as fs from '@std/fs';
|
||||
import * as path from '@std/path';
|
||||
|
||||
const DEFAULT_HANDLER_DIRECTORIES = [path.resolve(path.join(path.dirname(path.fromFileUrl(import.meta.url)), 'handlers'))];
|
||||
const DEFAULT_HANDLER_DIRECTORIES = [path.join(import.meta.dirname ?? '.', 'handlers')];
|
||||
|
||||
/** A `HANDLER` must take a `Request` and return a `Response` if it can handle it. */
|
||||
type HANDLER = (request: Request) => Promise<Response | null | undefined> | Response | null | undefined;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue