From b12a41cd7709f4892be962deae7d16dd2f10a10c Mon Sep 17 00:00:00 2001 From: Twentysix Date: Sat, 17 Jun 2017 19:12:53 +0200 Subject: [PATCH] [Dev] Fixed [p]repl, sanitize [p]eval output --- core/dev_commands.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/core/dev_commands.py b/core/dev_commands.py index f443a88fd..45a2feffb 100644 --- a/core/dev_commands.py +++ b/core/dev_commands.py @@ -135,6 +135,7 @@ class Dev: if ret is None: if value: + value = self.sanitize_output(ctx, value) await ctx.send(box(value, lang="py")) else: ret = self.sanitize_output(ctx, ret) @@ -208,7 +209,6 @@ class Dev: result = executor(code, variables) if inspect.isawaitable(result): result = await result - result = self.sanitize_output(ctx, result) except: value = stdout.getvalue() value = self.sanitize_output(ctx, value) @@ -223,6 +223,7 @@ class Dev: try: for page in pagify(msg, shorten_by=12): + page = self.sanitize_output(ctx, page) await ctx.send(box(page, "py")) except discord.Forbidden: pass