Skip to content

Commit

Permalink
fix type
Browse files Browse the repository at this point in the history
  • Loading branch information
cometkim committed Apr 25, 2024
1 parent ecc0a99 commit 01d9547
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 4 deletions.
2 changes: 1 addition & 1 deletion deno_dist/adapter/deno/serve-static.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export const serveStatic = <E extends Env = Env>(
} catch (e) {
console.warn(`${e}`)
}
return file ? file.readable : undefined
return file ? file.readable : null
}
const pathResolve = (path: string) => {
return `./${path}`
Expand Down
1 change: 0 additions & 1 deletion deno_dist/middleware/serve-static/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ const defaultPathResolve = (path: string) => path
*/
export const serveStatic = <E extends Env = Env>(
options: ServeStaticOptions<E> & {
// eslint-disable-next-line @typescript-eslint/no-explicit-any
getContent: (path: string, c: Context<E>) => Promise<Data | Response | null>
pathResolve?: (path: string) => string
}
Expand Down
2 changes: 1 addition & 1 deletion src/adapter/deno/serve-static.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export const serveStatic = <E extends Env = Env>(
} catch (e) {
console.warn(`${e}`)
}
return file ? file.readable : undefined
return file ? file.readable : null
}
const pathResolve = (path: string) => {
return `./${path}`
Expand Down
1 change: 0 additions & 1 deletion src/middleware/serve-static/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ const defaultPathResolve = (path: string) => path
*/
export const serveStatic = <E extends Env = Env>(
options: ServeStaticOptions<E> & {
// eslint-disable-next-line @typescript-eslint/no-explicit-any
getContent: (path: string, c: Context<E>) => Promise<Data | Response | null>
pathResolve?: (path: string) => string
}
Expand Down

0 comments on commit 01d9547

Please sign in to comment.