Skip to content

Commit 8a1f6be

Browse files
committed
fix: resolve worker path properly
1 parent 0b950ae commit 8a1f6be

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

lib/workers.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,9 @@
22

33
const chokidar = require('chokidar')
44
const config = require('../config')
5-
const fs = require('fs')
65
const mkdirp = require('mkdirp')
6+
const path = require('path')
7+
const fs = require('fs')
78

89
// Ensure the workers folder exists
910
mkdirp(config.get('workers.path'), (err, made) => {
@@ -26,7 +27,7 @@ mkdirp(config.get('workers.path'), (err, made) => {
2627
*/
2728
const Workers = function () {
2829
this.workers = {}
29-
this.workerPath = config.get('workers.path')
30+
this.workerPath = path.resolve(config.get('workers.path'))
3031

3132
// Load all workers from the configured worker path
3233
this.load(this.workerPath, this.workers)

0 commit comments

Comments
 (0)