File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
src/main/java/org/zendesk/client/v2 Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -881,6 +881,10 @@ public Iterable<SearchResultEntity> getSearchResults(String query) {
881
881
}
882
882
883
883
public <T extends SearchResultEntity > Iterable <T > getSearchResults (Class <T > type , String query ) {
884
+ return getSearchResults (type , query , null );
885
+ }
886
+
887
+ public <T extends SearchResultEntity > Iterable <T > getSearchResults (Class <T > type , String query , String params ) {
884
888
String typeName = null ;
885
889
for (Map .Entry <String , Class <? extends SearchResultEntity >> entry : searchResultTypes .entrySet ()) {
886
890
if (type .equals (entry .getValue ())) {
@@ -891,7 +895,9 @@ public <T extends SearchResultEntity> Iterable<T> getSearchResults(Class<T> type
891
895
if (typeName == null ) {
892
896
return Collections .emptyList ();
893
897
}
894
- return new PagedIterable <T >(tmpl ("/search.json{?query}" ).set ("query" , query + "+type:" + typeName ),
898
+ return new PagedIterable <T >(tmpl ("/search.json{?query,params}" )
899
+ .set ("query" , query + "+type:" + typeName )
900
+ .set ("params" , params ),
895
901
handleList (type , "results" ));
896
902
}
897
903
You can’t perform that action at this time.
0 commit comments