From 4a2811f4a3b398dd4ae9aa26fff527ead5a07e65 Mon Sep 17 00:00:00 2001 From: Dragon Fire Date: Sun, 31 May 2020 13:44:04 -0400 Subject: [PATCH] Fix --- commands/edit-meme/meme-gen-modern.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/commands/edit-meme/meme-gen-modern.js b/commands/edit-meme/meme-gen-modern.js index 759a7178..f212aadc 100644 --- a/commands/edit-meme/meme-gen-modern.js +++ b/commands/edit-meme/meme-gen-modern.js @@ -63,8 +63,11 @@ module.exports = class MemeGenModernCommand extends Command { ctx.font = '40px Noto'; const lines = await wrapText(ctx, text, base.width - 10); const lineBreakLen = text.split('\n').length; - const linesLen = (40 * lines.length) + (40 * (lineBreakLen - 1)) + (14 * lines.length) + (14 * (lineBreakLen - 1)); - canvas.height += linesLen + 5; + const linesLen = (40 * lines.length) + + (40 * (lineBreakLen - 1)) + + (14 * lines.length) + + (14 * (lineBreakLen - 1)); + canvas.height += linesLen + 14; ctx.font = '40px Noto'; ctx.textBaseline = 'top'; ctx.fillStyle = 'white';