Fixed tiny bug

Input to search function should not be NULL pointer.