fixed problems and fixed login issue