update function searchNode