adding search capability / refactoring
merging