Now checks database for username and password