Skip to content

Commit

Permalink
Fix for testing
Browse files Browse the repository at this point in the history
  • Loading branch information
lelemm committed Mar 4, 2025
1 parent 7f608a3 commit 0043111
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/sync-server/src/load-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ const projectRoot = path.dirname(path.dirname(fileURLToPath(import.meta.url)));
const defaultDataDir = process.env.ACTUAL_DATA_DIR
? process.env.ACTUAL_DATA_DIR
: fs.existsSync('/data')
? '/data'
: projectRoot;
? '/data'

Check failure on line 17 in packages/sync-server/src/load-config.js

View workflow job for this annotation

GitHub Actions / lint

Insert `··`
: projectRoot;

Check failure on line 18 in packages/sync-server/src/load-config.js

View workflow job for this annotation

GitHub Actions / lint

Insert `··`

debug(`Project root: '${projectRoot}'`);

Expand Down Expand Up @@ -58,7 +58,7 @@ const configSchema = convict({
dataDir: {
doc: 'Default data directory.',
format: String,
default: defaultDataDir,
default: process.env.NODE_ENV === 'test' ? projectRoot : defaultDataDir,
env: 'ACTUAL_DATA_DIR',
},
port: {
Expand Down

0 comments on commit 0043111

Please sign in to comment.