added basic authentication to any route that updates the database