1. fix null pointer exception during search ( cause unknown search type
)