bug fix in searchPipe