makes required corrections