Copium for old Node 18
| @@ -14,7 +14,6 @@ import multer from 'multer'; | ||
| 14 | 14 | import responseTime from 'response-time'; |
| 15 | 15 | import helmet from 'helmet'; |
| 16 | 16 | import bodyParser from 'body-parser'; |
| 17 | -import open, { apps } from 'open'; | |
| 18 | 17 | |
| 19 | 18 | // local library imports |
| 20 | 19 | import './fetch-patch.js'; |
| @@ -329,6 +328,10 @@ async function postSetupTasks(result) { | ||
| 329 | 328 | |
| 330 | 329 | if (cliArgs.browserLaunchEnabled) { |
| 331 | 330 | try { |
| 331 | + // TODO: This should be converted to a regular import when support for Node 18 is dropped | |
| 332 | + const openModule = await import('open'); | |
| 333 | + const { default: open, apps } = openModule; | |
| 334 | + | |
| 332 | 335 | function getBrowsers() { |
| 333 | 336 | const isAndroid = process.platform === 'android'; |
| 334 | 337 | if (isAndroid) { |