mirror of
https://github.com/hanzoai/next.js.git
synced 2026-10-30 14:46:38 +00:00
When using `nextConfig.i18n`, then static files for `404.html` and `500.html` were added multiple times to the list. These duplicate entries in `outputs.staticFiles` ended up causing race conditions in the Vercel adapter because the same output file path was written concurrently by multiple file operations.
13 lines
270 B
JavaScript
13 lines
270 B
JavaScript
import fs from 'fs/promises'
|
|
|
|
// @ts-check
|
|
/** @type {import('next').NextAdapter} */
|
|
const adapter = {
|
|
name: 'i18n-test-adapter',
|
|
async onBuildComplete(ctx) {
|
|
await fs.writeFile('build-complete.json', JSON.stringify(ctx, null, 2))
|
|
},
|
|
}
|
|
|
|
export default adapter
|