Added searching; refactored login

Added search
removed login specific methods
pep8 conforming edits