fixes multiparameter attributes on update; DRY and formatting