Added login authentication check, only users in the database can log in