aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Matteo Bertucci <[email protected]>2020-01-28 14:50:58 +0000
committerGravatar Matteo Bertucci <[email protected]>2020-01-28 14:50:58 +0000
commitb5730e0b07a4eb886710d71648ba4c0ffb4ebf79 (patch)
tree4bfb7c6e413fe742d603dd2613818f6aafdb8ddf
parentCorrect eval output to include the 11th line (diff)
Don't strip whitespaces during snekbox formatting
It could lead to a misleading result if it is stripped.
-rw-r--r--bot/cogs/snekbox.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/bot/cogs/snekbox.py b/bot/cogs/snekbox.py
index 00b8618e2..81951efd3 100644
--- a/bot/cogs/snekbox.py
+++ b/bot/cogs/snekbox.py
@@ -137,7 +137,7 @@ class Snekbox(Cog):
"""
log.trace("Formatting output...")
- output = output.strip(" \n")
+ output = output.rstrip("\n")
original_output = output # To be uploaded to a pasting service if needed
paste_link = None
@@ -171,7 +171,6 @@ class Snekbox(Cog):
if truncated:
paste_link = await self.upload_output(original_output)
- output = output.strip()
if not output:
output = "[No output]"