Increase testserver verbosity.
This commit is contained in:
+3
-3
@@ -23,9 +23,9 @@ wss.on('connection', function(ws) {
|
|||||||
console.log('/foo connected');
|
console.log('/foo connected');
|
||||||
ws.on('message', function(data, flags) {
|
ws.on('message', function(data, flags) {
|
||||||
if (flags.binary) { return; }
|
if (flags.binary) { return; }
|
||||||
console.log('/foo >>> ' + data);
|
console.log('>>> ' + data);
|
||||||
if (data == 'goodbye') { ws.send('galaxy'); }
|
if (data == 'goodbye') { console.log('<<< galaxy'); ws.send('galaxy'); }
|
||||||
if (data == 'hello') { ws.send('world'); }
|
if (data == 'hello') { console.log('<<< world'); ws.send('world'); }
|
||||||
});
|
});
|
||||||
ws.on('close', function() {
|
ws.on('close', function() {
|
||||||
console.log('Connection closed!');
|
console.log('Connection closed!');
|
||||||
|
|||||||
Reference in New Issue
Block a user