Made the lambda statement more resistant to errors

Made the statement better

pylint fix

Accidently left off parameter

Removed logout
Merge pull request #758 from edx/jonahstanley/fix-courseteam-test

Made the lambda statement more resistant to errors