From 7afa15a6ba071f4f2d027af59ce87ee3b74997aa Mon Sep 17 00:00:00 2001 From: Daniel Odendahl Jr Date: Mon, 20 Nov 2017 22:48:04 +0000 Subject: [PATCH] Beep --- commands/image-edit/demotivational-poster.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/commands/image-edit/demotivational-poster.js b/commands/image-edit/demotivational-poster.js index c8c74e8a..c733197a 100644 --- a/commands/image-edit/demotivational-poster.js +++ b/commands/image-edit/demotivational-poster.js @@ -57,7 +57,7 @@ module.exports = class DemotivationalPosterCommand extends Command { const ctx = canvas.getContext('2d'); ctx.fillStyle = 'white'; ctx.fillRect(0, 0, base.width, base.height); - ctx.drawImage(data, 69, 44, 612, data.height); + ctx.drawImage(data, 69, 44, 612, data.height === data.width ? 612 : data.height > 412 ? data.height : 412); ctx.drawImage(base, 0, 0); ctx.textAlign = 'center'; ctx.font = '60px Noto';