- We recommend you to create a unique channel for the bot and make him the only one who can send message in that channel.
- IMPORTANT: Let him read message ONLY on this channel to avoid people to troll
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
const http = require('http'); | |
function addGracefulShutdown(server) { | |
const oldClose = server.close; | |
const connections = {}; | |
let shouldDestroy = false; | |
let connectionId = 0; | |
function destroy(socket) { |