Skip to content

Commit

Permalink
additional logging
Browse files Browse the repository at this point in the history
  • Loading branch information
olegakbarov committed Mar 7, 2017
1 parent 1cabac3 commit 580f341
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions server.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,8 @@ const proxyEmitter = new SSE();
proxyEmitter.setMaxListeners(1);

app.post('/webhook', (req, res) => {
const data = req.body;
// Make sure this is a page subscription
if (data.object === 'page') {
proxyEmitter.emit('msg', data);
proxyEmitter.emit('msg', req);

// timeout here = 20sec
res.sendStatus(200);
Expand Down

0 comments on commit 580f341

Please sign in to comment.