Skip to content

Commit 2cb3fa3

Browse files
committed
PR review changes
1 parent dfa5cb8 commit 2cb3fa3

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/loader.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,13 @@ try {
1818
const sass = require("node-sass");
1919
const sassVersion = require("node-sass/package.json").version;
2020

21-
if (/^4[.]/.test(sassVersion)) {
21+
if (Number(sassVersion[0]) >= 4) {
2222
asyncSassJobQueue = async.queue(sass.render, threadPoolSize - 1);
2323
} else {
24-
loadingError = new Error("The installed version of \`node-sass\` is not compatible (expected: 4.x, actual: " + sassVersion + ").");
24+
throw new Error("The installed version of \`node-sass\` is not compatible (expected: 4.x, actual: " + sassVersion + ").");
2525
}
2626
} catch (e) {
27-
// ignored
27+
loadingError = e;
2828
}
2929

3030
/**

0 commit comments

Comments
 (0)