Added new method commit for generic save and rollback functionality
Pushed save and rollback logic to model