Fixed some mistakes in User authentication system