More concise error messages when root node entries are incorrect in index

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@2071 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Derek Hulley
2006-01-04 12:44:54 +00:00
parent 44828949fa
commit 9528d9d941

View File

@@ -215,9 +215,13 @@ public class LeafScorer extends Scorer
counter.count++;
}
}
if (parentIds.size() != 1)
if (parentIds.size() > 1)
{
throw new SearcherException("More than one root node? " + parentIds.size());
throw new SearcherException("More than one root node in index: " + parentIds.size());
}
else if (parentIds.size() == 0)
{
throw new SearcherException("Index has no root node. Check that the correct index locations are being used.");
}
}