GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Completed
Push — master ( 1b573f...d56bf7 )
by Vladimir
30s
created

index.js ➔ ???   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 2
Bugs 0 Features 0
Metric Value
cc 1
c 2
b 0
f 0
nc 1
dl 0
loc 3
rs 10
nop 0
1
const io = require('socket.io-client');
2
3
const app = require('./../app');
4
const renderJson = require('./../lib');
5
6
const socket = io.connect();
7
8
/**
9
 * Handler for WebSocket 'connect' event.
10
 * Emits 'join' event which is intended to join WebSocket room for current streamId.
11
 */
12
socket.on('connect', () => {
13
  socket.emit('join', app.getStreamId());
14
});
15
16
/**
17
 * Handler for new data.
18
 * Renders data on web page (add to the bottom).
19
 *
20
 * @event LOG.NEW
21
 */
22
socket.on('log', (data) => {
23
  // It is only way to render proper data because socket.io rooms disabled here
24
  // @see https://github.com/cn007b/log/blob/master/src/routes/index.js#L49
25
  if (data.streamId !== app.getStreamId()) {
26
    return;
27
  }
28
29
  if (data.format === 'json') {
30
    /** global: app */
31
    renderJson(data, app.getAutoScroll());
32
  }
33
});
34