coding style fixes

This commit is contained in:
Brandon Nozaki Miller 2016-01-10 04:32:46 -08:00
parent 1fe7e543ee
commit 32cfa88d9b
7 changed files with 12 additions and 4 deletions

View file

@ -182,8 +182,9 @@ function init(path,config,log,port){
function serverCreated(socket) {
server.sockets.push(socket);
if(socket.setEncoding)
if(socket.setEncoding){
socket.setEncoding(server.config.encoding);
}
server.log('## socket connection to server detected ##'.rainbow);
socket.on(
@ -219,8 +220,9 @@ function init(path,config,log,port){
return;
}
if(!this.ipcBuffer)
if(!this.ipcBuffer){
this.ipcBuffer='';
}
data=(this.ipcBuffer+=data);
@ -254,8 +256,10 @@ function init(path,config,log,port){
socket.on(
'message',
function(msg,rinfo) {
if (!rinfo)
if (!rinfo){
return;
}
server.log('Received UDP message from '.debug, rinfo.address.variable, rinfo.port);
let data;

View file

@ -1,3 +1,4 @@
/*global describe, expect, it*/
'use strict';
const ipc = require('../../../../node-ipc');

View file

@ -1,3 +1,4 @@
/*global describe, expect, it*/
'use strict';
const ipc = require('../../../../node-ipc');

View file

@ -1,3 +1,4 @@
/*global describe, expect, it*/
'use strict';
const ipc = require('../../../../node-ipc');

View file

@ -1,3 +1,4 @@
/*global describe, expect, it*/
'use strict';
const ipc = require('../../../../node-ipc');

View file

@ -1,3 +1,4 @@
/*global describe, expect, it*/
'use strict';
const ipc = require('../../../../node-ipc');

View file

@ -20,7 +20,6 @@ ipc.config.silent=true;
ipc.serve(
function serverStarted(){
let ready=false;
let messageDelay=500;
ipc.server.on(
'message',