diff --git a/package.json b/package.json index da27894d..b9dd2246 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "xiaobot", - "version": "18.9.2", + "version": "18.9.3", "description": "A Discord Bot", "main": "shardingmanager.js", "scripts": { diff --git a/structures/Cleverbot.js b/structures/Cleverbot.js index a2ba90e0..f563b230 100644 --- a/structures/Cleverbot.js +++ b/structures/Cleverbot.js @@ -1,31 +1,31 @@ const request = require('superagent'); class Cleverbot { - constructor(options) { - this.key = options.key; - this.user = options.user; - this.nick = options.nick; - } - - create() { - return request - .post('https://cleverbot.io/1.0/create') - .send({ - user: this.user, - key: this.key, - nick: this.nick - }); + constructor(options) { + this.key = options.key; + this.user = options.user; + this.nick = options.nick; } - + + create() { + return request + .post('https://cleverbot.io/1.0/create') + .send({ + user: this.user, + key: this.key, + nick: this.nick + }); + } + ask(text) { - return request - .post('https://cleverbot.io/1.0/ask') - .send({ - user: this.user, - key: this.key, - nick: this.nick, - text - }); + return request + .post('https://cleverbot.io/1.0/ask') + .send({ + user: this.user, + key: this.key, + nick: this.nick, + text + }); } }