Use 'bindings' module
This commit is contained in:
parent
044f394917
commit
60d5ab6abb
@ -6,16 +6,7 @@ var CopyFromStream = require(__dirname + '/../copystream').CopyFromStream;
|
||||
var CopyToStream = require(__dirname + '/../copystream').CopyToStream;
|
||||
var JsClient = require(__dirname + '/../client'); // used to import JS escape functions
|
||||
|
||||
var binding;
|
||||
|
||||
//TODO remove on v1.0.0
|
||||
try {
|
||||
//v0.5.x
|
||||
binding = require(__dirname + '/../../build/Release/binding.node');
|
||||
} catch(e) {
|
||||
//v0.4.x
|
||||
binding = require(__dirname + '/../../build/default/binding');
|
||||
}
|
||||
var binding = require('bindings')('binding.node');
|
||||
|
||||
var Connection = binding.Connection;
|
||||
var NativeQuery = require(__dirname + '/query');
|
||||
|
@ -18,13 +18,14 @@
|
||||
"author": "Brian Carlson <brian.m.carlson@gmail.com>",
|
||||
"main": "./lib",
|
||||
"dependencies": {
|
||||
"generic-pool": "2.1.1",
|
||||
"bindings": "^1.2.1",
|
||||
"buffer-writer": "1.0.0",
|
||||
"pgpass": "0.0.3",
|
||||
"generic-pool": "2.1.1",
|
||||
"nan": "~1.3.0",
|
||||
"packet-reader": "0.2.0",
|
||||
"pg-connection-string": "0.1.2",
|
||||
"pg-types": "1.4.0"
|
||||
"pg-types": "1.4.0",
|
||||
"pgpass": "0.0.3"
|
||||
},
|
||||
"devDependencies": {
|
||||
"jshint": "2.5.2",
|
||||
|
Loading…
Reference in New Issue
Block a user