Skip to content

Commit 381b13b

Browse files
committed
Allow using static handlers in Bun v1.3
1 parent 668c7a1 commit 381b13b

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/utils.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1078,6 +1078,8 @@ export const encodePath = (path: string, { dynamic = false } = {}) => {
10781078
export const supportPerMethodInlineHandler = (() => {
10791079
if (typeof Bun === 'undefined') return true
10801080

1081+
if (Bun.semver?.satisfies?.(Bun.version, '>=1.2.14')) return true
1082+
10811083
const semver = Bun.version.split('.')
10821084
if (+semver[0] < 1 || +semver[1] < 2 || +semver[2] < 14) return false
10831085

0 commit comments

Comments
 (0)