Socket
Socket
Sign inDemoInstall

pg

Package Overview
Dependencies
Maintainers
1
Versions
224
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pg - npm Package Compare versions

Comparing version 7.0.1 to 7.0.2

2

lib/client.js

@@ -403,3 +403,3 @@ 'use strict'

this.connection.stream.destroy(new Error('Connection terminated by user'))
return
return cb ? cb() : Promise.resolve()
}

@@ -406,0 +406,0 @@ if (cb) {

@@ -53,5 +53,4 @@ 'use strict'

NativeQuery.prototype.handleError = function (err) {
var self = this
// copy pq error fields into the error object
var fields = self.native.pq.resultErrorFields()
var fields = this.native.pq.resultErrorFields()
if (fields) {

@@ -63,8 +62,8 @@ for (var key in fields) {

}
if (self.callback) {
self.callback(err)
if (this.callback) {
this.callback(err)
} else {
self.emit('error', err)
this.emit('error', err)
}
self.state = 'error'
this.state = 'error'
}

@@ -71,0 +70,0 @@

@@ -73,3 +73,3 @@ 'use strict'

function prepareObject (val, seen) {
if (val.toPostgres && typeof val.toPostgres === 'function') {
if (val && typeof val.toPostgres === 'function') {
seen = seen || []

@@ -76,0 +76,0 @@ if (seen.indexOf(val) !== -1) {

{
"name": "pg",
"version": "7.0.1",
"version": "7.0.2",
"description": "PostgreSQL client - pure javascript & libpq with the same API",

@@ -5,0 +5,0 @@ "keywords": [

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc