From 4b6fc99a62b0d2da88bd3abb0aafc07460671e43 Mon Sep 17 00:00:00 2001 From: snowleo Date: Thu, 27 Oct 2011 00:06:15 +0200 Subject: Crop after 15KB and add a note, that it's cropped by the upload. --- .../src/com/earth2me/essentials/update/chat/AbstractFileCommand.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'EssentialsUpdate/src') diff --git a/EssentialsUpdate/src/com/earth2me/essentials/update/chat/AbstractFileCommand.java b/EssentialsUpdate/src/com/earth2me/essentials/update/chat/AbstractFileCommand.java index 12aa3326e..58bbb25b0 100644 --- a/EssentialsUpdate/src/com/earth2me/essentials/update/chat/AbstractFileCommand.java +++ b/EssentialsUpdate/src/com/earth2me/essentials/update/chat/AbstractFileCommand.java @@ -58,9 +58,10 @@ public abstract class AbstractFileCommand implements Command protected String uploadToPastie(final StringBuilder input) throws IOException { - if (input.length() > 10000) + if (input.length() > 15000) { - input.delete(0, input.length() - 10000); + input.delete(0, input.length() - 15000); + input.append("## Cropped after 15000 bytes"); } final PastieUpload pastie = new PastieUpload(); return pastie.send(input.toString()); -- cgit v1.2.3