fix: imports (part 2/2) (#13520)
Completes https://github.com/payloadcms/payload/pull/13513 That PR fixed it for the `admin` suite, but I had also encountered the same issue in `live-preview`. When searching for instances, I found others with the same pattern within packages, which I took the opportunity to fix in case the same error occurs in the future.
This commit is contained in:
@@ -2,7 +2,7 @@ import { createServer } from 'http'
|
||||
import next from 'next'
|
||||
import { parse } from 'url'
|
||||
|
||||
const actualNext = next.default || next
|
||||
const actualNext = 'default' in next ? next.default : next
|
||||
export const bootAdminPanel = async ({ port = 3000, appDir }) => {
|
||||
const serverURL = `http://localhost:${port}`
|
||||
const app = actualNext({
|
||||
|
||||
Reference in New Issue
Block a user