aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorAlex Mingoia <talk@alexmingoia.com>2016-05-10 22:04:44 -0700
committerAlex Mingoia <talk@alexmingoia.com>2016-05-10 22:04:44 -0700
commitf23665b22bf96eabdfbfc95f20348c9475e85ecd (patch)
tree870c702ddd6de586ac20a1e8797eb97f4773ba9b
parent7de41f10b4ff0f0d6b45d59bee0f166c3cfe3f9f (diff)
downloadpurs-loader-f23665b22bf96eabdfbfc95f20348c9475e85ecd.tar.gz
purs-loader-f23665b22bf96eabdfbfc95f20348c9475e85ecd.tar.zst
purs-loader-f23665b22bf96eabdfbfc95f20348c9475e85ecd.zip
Recompile on when psc-client-ide receives UnknownModule.
-rw-r--r--src/index.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/index.js b/src/index.js
index 0a25ccd..17951d3 100644
--- a/src/index.js
+++ b/src/index.js
@@ -222,7 +222,7 @@ function rebuild(psModule) {
222 if (!Array.isArray(res.result)) { 222 if (!Array.isArray(res.result)) {
223 return res.resultType === 'success' 223 return res.resultType === 'success'
224 ? resolve(psModule) 224 ? resolve(psModule)
225 : reject(res.result) 225 : reject(res)
226 } 226 }
227 227
228 Promise.map(res.result, (item, i) => { 228 Promise.map(res.result, (item, i) => {
@@ -232,7 +232,7 @@ function rebuild(psModule) {
232 .then(compileMessages => { 232 .then(compileMessages => {
233 if (res.resultType === 'error') { 233 if (res.resultType === 'error') {
234 cache.errors = compileMessages 234 cache.errors = compileMessages
235 reject(res.result) 235 reject(res)
236 } else { 236 } else {
237 cache.warnings = compileMessages 237 cache.warnings = compileMessages
238 resolve(psModule) 238 resolve(psModule)