diff --git a/src/class/CSCLI.ts b/src/class/CSCLI.ts index 16637df..c190fdc 100644 --- a/src/class/CSCLI.ts +++ b/src/class/CSCLI.ts @@ -80,11 +80,9 @@ export default class CSCLI { const parsed: { Username: string, Type: string, Message?: string, Data?: any, HMAC: string } = JSON.parse(args[0]); // FINISH VERIFICATION CHECKS const handler: Handler = this.handlers.get(parsed.Type); - console.log(handler); if (!handler) return socket.destroy(); const context = new Context(socket, args[0], this.client); - console.log(context); await handler.handle(context); if (!context.socket.destroyed) { socket.destroy(); diff --git a/src/class/Context.ts b/src/class/Context.ts index 45a41b5..6e54f7b 100644 --- a/src/class/Context.ts +++ b/src/class/Context.ts @@ -29,8 +29,8 @@ export default class Context { } public send(v: string) { - console.log('writing or whateva'); - this.socket.write(`${v.toString()}\n`, (err) => this.client.signale.error(`Error occurred while writing: ${err}`)); + console.log(this.socket); + this.socket.write(`${v.toString()}\n`, (err) => err || this.client.signale.error(`Error occurred while writing: ${err}`)); this.socket.destroy(); } } diff --git a/src/cscli/ram.ts b/src/cscli/ram.ts index 03bbc86..1d74cd4 100644 --- a/src/cscli/ram.ts +++ b/src/cscli/ram.ts @@ -8,9 +8,7 @@ export default class RAM extends Handler { } public async handle(ctx: Context) { - console.log('1'); const memoryConversion = dataConversion(Number(await ctx.client.util.exec(`memory ${ctx.data.username}`)) * 1000); - console.log(memoryConversion); return ctx.send(memoryConversion); } }