From 0ee8e0e5239e3f76911834da54d2c72a4a149804 Mon Sep 17 00:00:00 2001 From: schneefux Date: Tue, 9 May 2017 18:02:15 +0200 Subject: error handling, migration to template --- views/guild.js | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) (limited to 'views/guild.js') diff --git a/views/guild.js b/views/guild.js index a5eedef..23c2afe 100644 --- a/views/guild.js +++ b/views/guild.js @@ -24,16 +24,11 @@ module.exports = class extends View { "", "vainsocial-guild-view") .setDescription(await this.text(guild.members)); return embed; - }; + } - async respond(guild) { - if (guild == undefined) { - this.response = await util.respond(this.msg, - strings.notRegistered, this.response); - return this.response; - } + async respond(guild, extra="") { this.response = await util.respond(this.msg, await this.embed(guild), this.response); return this.response; - }; + } } -- cgit v1.3.1