Skip to content

Commit 6fbdd19

Browse files
committed
fix codestyle
1 parent 87e4f2a commit 6fbdd19

2 files changed

Lines changed: 24 additions & 16 deletions

File tree

node.js/pubnub.js

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2080,7 +2080,7 @@ function xdr( setup ) {
20802080

20812081
url = '/' + url.split('/').slice(3).join('/');
20822082

2083-
var origin = setup.url[0].split("//")[1]
2083+
var origin = setup.url[0].split("//")[1];
20842084

20852085
options.hostname = proxy ? proxy.hostname : setup.url[0].split("//")[1];
20862086
options.port = proxy ? proxy.port : ssl ? 443 : 80;
@@ -2184,7 +2184,7 @@ function crypto_obj() {
21842184
}
21852185

21862186
function keepAliveIsEmbedded() {
2187-
return 'EventEmitter' in http.Agent.super_;
2187+
return 'EventEmitter' in http.Agent.super_;
21882188
}
21892189

21902190

@@ -2201,23 +2201,27 @@ var CREATE_PUBNUB = function(setup) {
22012201
keepAliveAgent = undefined;
22022202
}
22032203

2204-
SELF = function(setup) {
2204+
var SELF = function(setup) {
22052205
return CREATE_PUBNUB(setup);
2206-
}
2206+
};
2207+
22072208
var PN = PN_API(setup);
2209+
22082210
for (var prop in PN) {
22092211
if (PN.hasOwnProperty(prop)) {
22102212
SELF[prop] = PN[prop];
22112213
}
22122214
}
2215+
22132216
SELF.init = SELF;
22142217
SELF.secure = SELF;
22152218
SELF.ready();
2219+
22162220
return SELF;
2217-
}
2218-
CREATE_PUBNUB.init = CREATE_PUBNUB;
2221+
};
22192222

2220-
CREATE_PUBNUB.unique = unique
2223+
CREATE_PUBNUB.init = CREATE_PUBNUB;
2224+
CREATE_PUBNUB.unique = unique;
22212225
CREATE_PUBNUB.secure = CREATE_PUBNUB;
2222-
module.exports = CREATE_PUBNUB
2226+
module.exports = CREATE_PUBNUB;
22232227
module.exports.PNmessage = PNmessage;

node.js/unassembled/platform.js

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ function xdr( setup ) {
127127

128128
url = '/' + url.split('/').slice(3).join('/');
129129

130-
var origin = setup.url[0].split("//")[1]
130+
var origin = setup.url[0].split("//")[1];
131131

132132
options.hostname = proxy ? proxy.hostname : setup.url[0].split("//")[1];
133133
options.port = proxy ? proxy.port : ssl ? 443 : 80;
@@ -231,7 +231,7 @@ function crypto_obj() {
231231
}
232232

233233
function keepAliveIsEmbedded() {
234-
return 'EventEmitter' in http.Agent.super_;
234+
return 'EventEmitter' in http.Agent.super_;
235235
}
236236

237237

@@ -248,23 +248,27 @@ var CREATE_PUBNUB = function(setup) {
248248
keepAliveAgent = undefined;
249249
}
250250

251-
SELF = function(setup) {
251+
var SELF = function(setup) {
252252
return CREATE_PUBNUB(setup);
253-
}
253+
};
254+
254255
var PN = PN_API(setup);
256+
255257
for (var prop in PN) {
256258
if (PN.hasOwnProperty(prop)) {
257259
SELF[prop] = PN[prop];
258260
}
259261
}
262+
260263
SELF.init = SELF;
261264
SELF.secure = SELF;
262265
SELF.ready();
266+
263267
return SELF;
264-
}
265-
CREATE_PUBNUB.init = CREATE_PUBNUB;
268+
};
266269

267-
CREATE_PUBNUB.unique = unique
270+
CREATE_PUBNUB.init = CREATE_PUBNUB;
271+
CREATE_PUBNUB.unique = unique;
268272
CREATE_PUBNUB.secure = CREATE_PUBNUB;
269-
module.exports = CREATE_PUBNUB
273+
module.exports = CREATE_PUBNUB;
270274
module.exports.PNmessage = PNmessage;

0 commit comments

Comments
 (0)