Fix rollback/commit to work properly