Fix search
- The User.search function was called with completely wrong arguments and didn't have actually relevant tests.
- I boosted the search rank for friends so they should in nearly all cases be on top of the search results.
Closes #960 (closed).
Closes #960 (closed).