mirror of
https://github.com/directus/directus.git
synced 2026-04-25 03:00:53 -04:00
fix __dirname being undefined (#19955)
This commit is contained in:
@@ -5,6 +5,10 @@ import path from 'path';
|
||||
import env from '../env.js';
|
||||
import logger from '../logger.js';
|
||||
import { Url } from '../utils/url.js';
|
||||
import { dirname } from 'node:path';
|
||||
import { fileURLToPath } from 'node:url';
|
||||
|
||||
const __dirname = dirname(fileURLToPath(import.meta.url));
|
||||
|
||||
export const getSharedDepsMapping = async (deps: string[]): Promise<Record<string, string>> => {
|
||||
const appDir = await readdir(path.join(resolvePackage('@directus/app', __dirname), 'dist', 'assets'));
|
||||
|
||||
Reference in New Issue
Block a user