Skip to content

Commit 059a2fc

Browse files
author
Kibae Shin
committed
Simplify codes for replication parameter
1 parent f1d3cae commit 059a2fc

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

lib/client.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ Client.prototype.getStartupConf = function() {
224224
data.application_name = appName;
225225
}
226226
if (params.replication) {
227-
data.replication = params.replication === true ? 'true' : params.replication;
227+
data.replication = '' + params.replication;
228228
}
229229

230230
return data;

lib/connection-parameters.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ ConnectionParameters.prototype.getLibpqConnectionString = function(cb) {
9090
params.push("dbname='" + this.database + "'");
9191
}
9292
if(this.replication) {
93-
params.push("replication='" + (this.replication === true ? "true" : this.replication) + "'");
93+
params.push("replication='" + this.replication + "'");
9494
}
9595
if(this.host) {
9696
params.push("host=" + this.host);

0 commit comments

Comments
 (0)