From 6fc07b4a6301cf42c9680f2c398ad0ea52322c2b Mon Sep 17 00:00:00 2001 From: Mikkel Hoegh Date: Wed, 5 Dec 2018 00:01:39 +0100 Subject: [PATCH] fix: remove support for deprecated pg.js package BREAKING CHANGE: pg.js is long dead and no longer supported. Use [pg](https://www.npmjs.com/package/pg) instead. --- index.js | 4 ++-- pg.js | 10 ---------- 2 files changed, 2 insertions(+), 12 deletions(-) delete mode 100644 pg.js diff --git a/index.js b/index.js index 2c33a23..a444fc8 100644 --- a/index.js +++ b/index.js @@ -1,6 +1,6 @@ 'use strict' -const Result = require('./pg').Result -const prepare = require('./pg').prepareValue +const Result = require('pg/lib/result.js') +const prepare = require('pg/lib/utils.js').prepareValue const EventEmitter = require('events').EventEmitter const util = require('util') diff --git a/pg.js b/pg.js deleted file mode 100644 index 42d89a9..0000000 --- a/pg.js +++ /dev/null @@ -1,10 +0,0 @@ -// support both pg & pg.js -// this will eventually go away when i break native bindings -// out into their own module -try { - module.exports.Result = require('pg/lib/result.js') - module.exports.prepareValue = require('pg/lib/utils.js').prepareValue -} catch (e) { - module.exports.Result = require('pg.js/lib/result.js') - module.exports.prepareValue = require('pg.js/lib/utils.js').prepareValue -}