mirror of
https://github.com/cpvalente/ontime.git
synced 2026-08-05 15:33:59 +00:00
remove redundant path evaluation
This commit is contained in:
@@ -59,17 +59,13 @@ const currentDir = dirname(__dirname);
|
||||
export const srcDirectory = isProduction ? currentDir : path.join(currentDir, '../');
|
||||
|
||||
// resolve path to external
|
||||
const productionPath = path.join(srcDirectory, '../../resources/extraResources/client');
|
||||
const productionPath = path.join(srcDirectory, 'client/');
|
||||
const devPath = path.join(srcDirectory, '../../client/build/');
|
||||
const dockerPath = path.join(srcDirectory, 'client/');
|
||||
|
||||
export const resolvedPath = (): string => {
|
||||
if (isTest) {
|
||||
return devPath;
|
||||
}
|
||||
if (isDocker) {
|
||||
return dockerPath;
|
||||
}
|
||||
if (isProduction) {
|
||||
return productionPath;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user