From e224cd15738d39cbbeaaffd6fff2a9320128a5a2 Mon Sep 17 00:00:00 2001 From: shaiherman Date: Fri, 6 Feb 2015 14:32:06 -0600 Subject: [PATCH] Update grant/ and exchange/ requires to use function expressions for compatibility with strict mode --- lib/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/index.js b/lib/index.js index 2c94c32d..8fc68df9 100644 --- a/lib/index.js +++ b/lib/index.js @@ -39,7 +39,7 @@ exports.grant = {}; fs.readdirSync(__dirname + '/grant').forEach(function(filename) { if (/\.js$/.test(filename)) { var name = path.basename(filename, '.js'); - function load() { return require('./grant/' + name); } + var load = function () { return require('./grant/' + name); }; exports.grant.__defineGetter__(name, load); } }); @@ -56,7 +56,7 @@ exports.exchange = {}; fs.readdirSync(__dirname + '/exchange').forEach(function(filename) { if (/\.js$/.test(filename)) { var name = path.basename(filename, '.js'); - function load() { return require('./exchange/' + name); } + var load = function () { return require('./exchange/' + name); }; exports.exchange.__defineGetter__(name, load); } });