Fix so app doesn't crash with empty search terms

I don’t like this solution.