throw new QueryParsingException(parseContext.index(), "Type [" + childType + "] does not have parent mapping");
}
String parentType = childDocMapper.parentFieldMapper().type();
query = new FilteredQuery(query, parseContext.cacheFilter(childDocMapper.typeFilter(), null));
SearchContext searchContext = SearchContext.current();
<BUG>HasChildFilter childFilter = new HasChildFilter(query, scope, childType, parentType, searchContext);
</BUG>
searchContext.addScopePhase(childFilter);
if (filterName != null) {
parseContext.addNamedFilter(filterName, childFilter);

throw new QueryParsingException(parseContext.index(), "Type [" + childType + "] does not have parent mapping");
}
String parentType = childDocMapper.parentFieldMapper().type();
query = new FilteredQuery(query, parseContext.cacheFilter(childDocMapper.typeFilter(), null));
SearchContext searchContext = SearchContext.current();
HasChildFilter childFilter = HasChildFilter.create(query, scope, parentType, childType, searchContext, executionType);
searchContext.addScopePhase(childFilter);
if (filterName != null) {
parseContext.addNamedFilter(filterName, childFilter);
