Skip to content

Commit

Permalink
Comment loadPackage override
Browse files Browse the repository at this point in the history
Fixes:

    /usr/src/app/node_modules/meld/meld.js:67
                      if (typeof target[pointcut] === 'function') {
                                        ^

    TypeError: Cannot read property 'loadPackage' of undefined
        at meld (/usr/src/app/node_modules/meld/meld.js:67:23)
        at Function.around (/usr/src/app/node_modules/meld/meld.js:436:12)
        at patcher (/usr/src/app/lib/eslint-patch.js:21:8)
        at Object.<anonymous> (/usr/src/app/bin/eslint.js:11:44)
        at Module._compile (module.js:397:26)
        at Object.Module._extensions..js (module.js:404:10)
        at Module.load (module.js:343:32)
        at Function.Module._load (module.js:300:12)
        at Function.Module.runMain (module.js:429:10)
        at startup (node.js:139:18)
  • Loading branch information
pbrisbin committed May 26, 2016
1 parent 1f111fc commit 5ca5f43
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions lib/eslint-patch.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,14 @@ module.exports = function patcher(eslint) {
return;
});

meld.around(eslint.CLIEngine.Config, 'loadPackage', function(joinPoint) {
var filePath = joinPoint.args[0];
if (filePath.match(/^eslint-config-airbnb.*/)) {
return joinPoint.proceed();
} else {
return {};
}
});
// meld.around(eslint.CLIEngine.Config, 'loadPackage', function(joinPoint) {
// var filePath = joinPoint.args[0];
// if (filePath.match(/^eslint-config-airbnb.*/)) {
// return joinPoint.proceed();
// } else {
// return {};
// }
// });

eslint.docs = docs;

Expand Down

0 comments on commit 5ca5f43

Please sign in to comment.