search function working few bugs under dev