Finishes Login functionality