Skip to content

Commit 8da732a

Browse files
committed
chore: fix for prod
1 parent 7728586 commit 8da732a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

_nuxthub/server/utils/bucket.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ export function useBucket (name: string = '') {
1212
console.log('Using R2 local (proxy for useBucket() is not yet supported)')
1313
}
1414
// @ts-ignore
15-
const binding = globalThis[bucketName]
15+
const binding = process.env[bucketName] || globalThis.__env__?.[bucketName] || globalThis[bucketName]
1616
if (!binding) {
1717
throw createError(`Missing Cloudflare R2 binding ${bucketName}`)
1818
}

0 commit comments

Comments
 (0)