- don't show empty "did you mean"

git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@6061 6c8d7289-2bf4-0310-a012-ef5d649a1542
pull/1/head
apfelmaennchen 16 years ago
parent 6c116be536
commit 9150bc0f7d

@ -471,8 +471,9 @@ public class yacysearch {
// check suggestions
int meanMax = 0;
if (post != null && post.containsKey("meanCount")) {
meanMax = Integer.parseInt(post.get("meanCount"));
meanMax = Integer.parseInt(post.get("meanCount"));
}
prop.put("meanCount", meanMax);
if(meanMax > 0) {
DidYouMean didYouMean = new DidYouMean(sb);
Iterator<String> meanIt = didYouMean.getSuggestion(querystring).iterator();
@ -499,7 +500,7 @@ public class yacysearch {
meanCount++;
}
prop.put("didYouMean_suggestions_"+(meanCount-1)+"_sep","");
prop.put("didYouMean", 1);
prop.put("didYouMean", meanCount>0 ? 1:0);
prop.put("didYouMean_suggestions", meanCount);
} else {
prop.put("didYouMean", 0);

Loading…
Cancel
Save