Fixes #3767: Group API V5 refuse creating group with empty query
Merge pull request #690 from VinceMacBuche/bug_3767/with_the_api_it_is_possible_to_set_group_without_any_criteria

Fixes #3767: Group API V5 refuse creating group with empty query