Fix staff advanced search when more than two queries
Fix bug in public advanced search where exception is raised when building the advanced_query when more than 2 fields are provided.