WebSearch: bugfix for empty set sorting
- When search finds no results, the 'results_final' datastructure is not set properly, which in turn creates problems for the ranking/filtering/sorting (they expect dictionary, not 'None').
This commit fixes th problem and adds this case to regression tests.