tried to cleanup a bit and render automatic login but unsuccessfully