Skip to content

Commit f9390da

Browse files
committed
Re-implement changes from conflict
1 parent 8bfdd39 commit f9390da

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

lib/client.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -40,11 +40,11 @@ var Client = function (config) {
4040
this.connection = c.connection || new Connection({
4141
stream: c.stream,
4242
ssl: this.connectionParameters.ssl,
43-
keepAlive: c.keepAlive || false
43+
keepAlive: c.keepAlive || false,
44+
encoding: this.connectionParameters.client_encoding || 'utf8'
4445
})
4546
this.queryQueue = []
4647
this.binary = c.binary || defaults.binary
47-
this.encoding = 'utf8'
4848
this.processID = null
4949
this.secretKey = null
5050
this.ssl = this.connectionParameters.ssl || false

lib/connection.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ var Connection = function (config) {
2525
this.lastOffset = 0
2626
this.buffer = null
2727
this.offset = null
28-
this.encoding = 'utf8'
28+
this.encoding = config.encoding || 'utf8'
2929
this.parsedStatements = {}
3030
this.writer = new Writer()
3131
this.ssl = config.ssl || false

0 commit comments

Comments
 (0)