minor login functunality