fix try/catch bug (bad err reference)

This commit is contained in:
AJ ONeal 2015-02-16 02:30:52 +00:00
parent b66b6e31f9
commit 705671a96a
1 changed files with 2 additions and 2 deletions

View File

@ -83,7 +83,7 @@ function getAppContext(domaininfo) {
// TODO pass in websocket
localApp = localApp.create(/*config*/);
if (!localApp) {
return getDummyAppContext(err, "[ERROR] no app was returned by app.js for " + domaininfo.driname);
return getDummyAppContext(null, "[ERROR] no app was returned by app.js for " + domaininfo.driname);
}
}
if (!localApp.then) {
@ -94,7 +94,7 @@ function getAppContext(domaininfo) {
});
}
} catch(e) {
localApp = getDummyAppContext(err, "[ERROR] could not load app.js for " + domaininfo.dirname);
localApp = getDummyAppContext(e, "[ERROR] could not load app.js for " + domaininfo.dirname);
localApp = PromiseA.resolve(localApp);
return localApp;