From: Marcin Koziej Date: Fri, 2 Nov 2012 13:08:54 +0000 (+0100) Subject: Off by one error X-Git-Url: https://git.mdrn.pl/wolnelektury.git/commitdiff_plain/1bae026e15a391213f57020fa0aab71840b052ff?hp=--cc Off by one error --- 1bae026e15a391213f57020fa0aab71840b052ff diff --git a/apps/search/custom.py b/apps/search/custom.py index e6f559b62..924a10ec6 100644 --- a/apps/search/custom.py +++ b/apps/search/custom.py @@ -147,7 +147,7 @@ class CustomSolrInterface(sunburnt.SolrInterface): break start -= 1 - while end < totlen: + while end < totlen - 1: if is_boundary(text[end + 1]): break end += 1