File tree 2 files changed +7
-1
lines changed
2 files changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -20,6 +20,7 @@ var Client = function(config) {
20
20
this . connection = config . connection || new Connection ( { stream : config . stream } ) ;
21
21
this . queryQueue = [ ] ;
22
22
this . password = config . password || defaults . password ;
23
+ this . binary = config . binary || defaults . binary ;
23
24
this . encoding = 'utf8' ;
24
25
this . processID = null ;
25
26
this . secretKey = null ;
@@ -173,6 +174,9 @@ p._pulseQueryQueue = function() {
173
174
p . query = function ( config , values , callback ) {
174
175
//can take in strings or config objects
175
176
config = ( typeof ( config ) == 'string' ) ? { text : config } : config ;
177
+ if ( this . binary && ! ( 'binary' in config ) ) {
178
+ config . binary = true ;
179
+ }
176
180
177
181
if ( values ) {
178
182
if ( typeof values === 'function' ) {
Original file line number Diff line number Diff line change @@ -14,5 +14,7 @@ module.exports = {
14
14
//0 will disable connection pooling
15
15
poolSize : 10 ,
16
16
//duration of node-pool timeout
17
- poolIdleTimeout : 30000
17
+ poolIdleTimeout : 30000 ,
18
+ // binary result mode
19
+ binary : false
18
20
}
You can’t perform that action at this time.
0 commit comments