Make login fully functional