Fix require problem for pg module

Closes #3
This commit is contained in:
Brian M. Carlson 2014-02-26 06:48:05 -06:00
parent a3074e9d54
commit 4925172530

View File

@ -6,7 +6,7 @@ var pgPath;
try {
pgPath = path.dirname(require.resolve('pg'))
} catch(e) {
pgPath = path.dirname(require.resolve('pg.js'))
pgPath = path.dirname(require.resolve('pg.js')) + '/lib'
}
module.exports = require(path.join(pgPath, 'lib', 'result.js'))
module.exports = require(path.join(pgPath, 'result.js'))