From cc017d70d2ad33fb3db2a14ed0a7a290e51978e1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Mart=C3=AD?= Date: Tue, 29 Sep 2015 20:39:36 -0700 Subject: [PATCH] Fix for bb2cbd527b --- fdroidserver/common.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/fdroidserver/common.py b/fdroidserver/common.py index 1c3ab8e4..f656ac09 100644 --- a/fdroidserver/common.py +++ b/fdroidserver/common.py @@ -1099,16 +1099,16 @@ class FDroidException(Exception): self.value = value self.detail = detail - def limit_size(detail): - if len(detail) < 16000: - return detail - return '[...]\n' + detail[-16000:] + def shortened_detail(self): + if len(self.detail) < 16000: + return self.detail + return '[...]\n' + self.detail[-16000:] def get_wikitext(self): ret = repr(self.value) + "\n" if self.detail: ret += "=detail=\n" - ret += "
\n" + limit_size(self.detail) + "
\n" + ret += "
\n" + self.shortened_detail() + "
\n" return ret def __str__(self):