PEP 8 fixes and a small improvment in an if statement.