Fixed issue in search engine (multiple identical matches returned when search query contained the same work multiple times).
This commit is contained in:
parent
4bb5211191
commit
e225f06bd1
6 changed files with 45 additions and 5 deletions
|
@ -489,7 +489,8 @@ namespace ScrewTurn.Wiki {
|
|||
len = sb.Length - start;
|
||||
endsAtEnd = true;
|
||||
}
|
||||
else if(len > maxLen) len = maxLen;
|
||||
if(len <= 0) len = sb.Length; // HACK: This should never occur, but if it does it crashes the wiki, so set it to max len
|
||||
if(len > maxLen) len = maxLen;
|
||||
|
||||
result = sb.ToString();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue