Skip to content

Commit

Permalink
throw a more useful exception if the field does not exist
Browse files Browse the repository at this point in the history
  • Loading branch information
mdavis95 committed Jun 14, 2023
1 parent 8a7ba58 commit 71bd742
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -414,6 +414,10 @@ private Query getTermInSetQuery(ZuliaQuery.Query query, String field) {

IndexFieldInfo indexFieldInfo = indexConfig.getIndexFieldInfo(field);

if (indexFieldInfo == null) {
throw new RuntimeException("Field <" + field + "> is not indexed");
}

String sortField = indexFieldInfo.getInternalSortFieldName();

if (sortField != null) {
Expand Down

0 comments on commit 71bd742

Please sign in to comment.