dynamic sentence to remove error messages