changed the call to the database