Fixes Client side of login procedure