From ff2fdcea2fe41a1487df1d8a696a38c990c48094 Mon Sep 17 00:00:00 2001 From: Daniel Odendahl Jr Date: Fri, 10 Nov 2017 14:18:02 +0000 Subject: [PATCH] canvas succ --- commands/avatar-edit/demotivational-poster.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/commands/avatar-edit/demotivational-poster.js b/commands/avatar-edit/demotivational-poster.js index 78e5b3eb..aeaaf699 100644 --- a/commands/avatar-edit/demotivational-poster.js +++ b/commands/avatar-edit/demotivational-poster.js @@ -23,7 +23,8 @@ module.exports = class DemotivationalPosterCommand extends Command { { key: 'title', prompt: 'What should the title of the poster be?', - type: 'string' + type: 'string', + parse: title => title.toUpperCase() }, { key: 'text', @@ -60,7 +61,7 @@ module.exports = class DemotivationalPosterCommand extends Command { ctx.fillText(title, 375, 518); ctx.font = '27px Noto'; ctx.fillStyle = 'white'; - ctx.fillText(text, 375, 570); + ctx.fillText(text, 375, 565); return msg.say({ files: [{ attachment: canvas.toBuffer(), name: 'demotivational-poster.png' }] }); } catch (err) { return msg.reply(`Oh no, an error occurred: \`${err.message}\`. Try again later!`);