fixed search result when it's nothing and fixed searching because it broke