Fixed small bug that caused search to crash