fixed bugs and re configured the login mechanisms