Fixed pep8 stuff
Fixed some bugs