diff options
author | snowleo <schneeleo@gmail.com> | 2011-10-27 00:06:15 +0200 |
---|---|---|
committer | snowleo <schneeleo@gmail.com> | 2011-10-27 00:06:15 +0200 |
commit | 4b6fc99a62b0d2da88bd3abb0aafc07460671e43 (patch) | |
tree | 9b07b51b7646116e95c367b48df00bf37410870e /EssentialsUpdate/src/com/earth2me/essentials/update/chat | |
parent | 60b9d4fc80c881ce5548f7387c3de0d9fc5a7637 (diff) | |
download | Essentials-4b6fc99a62b0d2da88bd3abb0aafc07460671e43.tar Essentials-4b6fc99a62b0d2da88bd3abb0aafc07460671e43.tar.gz Essentials-4b6fc99a62b0d2da88bd3abb0aafc07460671e43.tar.lz Essentials-4b6fc99a62b0d2da88bd3abb0aafc07460671e43.tar.xz Essentials-4b6fc99a62b0d2da88bd3abb0aafc07460671e43.zip |
Crop after 15KB and add a note, that it's cropped by the upload.
Diffstat (limited to 'EssentialsUpdate/src/com/earth2me/essentials/update/chat')
-rw-r--r-- | EssentialsUpdate/src/com/earth2me/essentials/update/chat/AbstractFileCommand.java | 5 |
1 files changed, 3 insertions, 2 deletions
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()); |