Fixed a bug with location search