Fixed PEP8 and Pyflakes errors