1 | const fileStat = require('./util/fileStat');
|
2 |
|
3 |
|
4 | exports = module.exports = option => {
|
5 | // const optionsValidationErrors = validateSchema(optionsSchema, options);
|
6 | // if (optionsValidationErrors.length) {
|
7 | // throw new Error(optionsValidationErrors);
|
8 | // }
|
9 |
|
10 |
|
11 | if (!fileStat.isDirectory(option.root)) {
|
12 | throw new Error('Invalid argument: `option.root` must be directory');
|
13 | }
|
14 | };
|