Skip to content

Commit

Permalink
fis filter
Browse files Browse the repository at this point in the history
  • Loading branch information
Rufim committed Jan 6, 2018
1 parent 72b0ba7 commit a5a97dd
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -100,11 +100,11 @@ public void setQuery(String query) {
}

public void setFilters(String string, Genre genre, Type type, Integer size, SortWorksBy sort) {
if (string != null) request.addParam(SearchParams.query, string);
if (type != null) request.addParam(SearchParams.type, type.name());
if (genre != null) request.addParam(SearchParams.genre, genre.name());
if (sort != null) request.addParam(SearchParams.sort, sort.name());
if (size != null && size > 0) request.addParam(SearchParams.work_size, size);
if (string != null) request.addParam(SearchParams.query, string); else request.addParam(SearchParams.query, "");
if (type != null) request.addParam(SearchParams.type, type.name()); else request.addParam(SearchParams.type, "");
if (genre != null) request.addParam(SearchParams.genre, genre.name()); else request.addParam(SearchParams.genre, "");
if (sort != null) request.addParam(SearchParams.sort, sort.name()); else request.addParam(SearchParams.sort, "");
if (size != null && size > 0) request.addParam(SearchParams.work_size, size); else request.addParam(SearchParams.work_size, "");
}

@Override
Expand Down

0 comments on commit a5a97dd

Please sign in to comment.