Fix bug in home search