Adding autobind decorator to server

This commit is contained in:
John Lyon-Smith
2018-03-26 11:37:18 -07:00
parent 80c37f8642
commit 49ca7f3bf1
18 changed files with 51 additions and 55 deletions

View File

@@ -7,12 +7,11 @@ import readlineSync from 'readline-sync'
import crypto from 'crypto'
import urlSafeBase64 from 'urlsafe-base64'
import util from 'util'
import autobind from 'autobind-decorator'
import autoBind from 'auto-bind2'
@autobind
class AddUserTool {
constructor(toolName, log) {
autoBind(this)
this.toolName = toolName
this.log = log
}

View File

@@ -4,11 +4,11 @@ import JSON5 from 'json5'
import fs from 'fs'
import uuidv4 from 'uuid/v4'
import chalk from 'chalk'
import autoBind from 'auto-bind2'
import autobind from 'autobind-decorator'
@autobind
class SendMessageTool {
constructor(toolName, log) {
autoBind(this)
this.toolName = toolName
this.log = log
}