function cleanUpAfterUndo(aCommands) {
			var aPromises = [];
			aCommands.forEach(function(oCommand) {
				var oChange = oCommand.getPreparedChange();
				if (oCommand.getAppComponent) {
					aPromises.push(PersistenceWriteAPI.remove({change: oChange, selector: oCommand.getAppComponent()}));
				}
			});
			return Promise.all(aPromises);
		}
/**
		 * Since we don't use the CommandStack here, we have to take care of the applied Changes,
		 * which are stored in the custom data of the control, ourselves;
		 * The original Change doesn't get deleted there, and therefore can't be applied again without this
		 *
		 * @param {sap.ui.rta.command.BaseCommand[]} aCommands Commands whose change should be cleaned up
		 * @return {Promise} resolves when cleanup after undo is done
		 */
Since we don't use the CommandStack here, we have to take care of the applied Changes,
which are stored in the custom data of the control, ourselves;
The original Change doesn't get deleted there, and therefore can't be applied again without this

@param {sap.ui.rta.command.BaseCommand[]} aCommands Commands whose change should be cleaned up
@return {Promise} resolves when cleanup after undo is done
Since we don ' t use the CommandStack here we have to take care of the applied Changes which are stored in the custom data of the control ourselves ; The original Change doesn ' t get deleted there and therefore can ' t be applied again without this @param { sap . ui . rta . command . BaseCommand [] } aCommands Commands whose change should be cleaned up @return { Promise } resolves when cleanup after undo is done
function cleanUpAfterUndo(aCommands) {
			var aPromises = [];
			aCommands.forEach(function(oCommand) {
				var oChange = oCommand.getPreparedChange();
				if (oCommand.getAppComponent) {
					aPromises.push(PersistenceWriteAPI.remove({change: oChange, selector: oCommand.getAppComponent()}));
				}
			});
			return Promise.all(aPromises);
		}
function cleanUpAfterUndo ( aCommands ) { var aPromises = [ ] ; aCommands . forEach ( function ( oCommand ) { var oChange = oCommand . getPreparedChange ( ) ; if ( oCommand . getAppComponent ) { aPromises . push ( PersistenceWriteAPI . remove ( { change : oChange , selector : oCommand . getAppComponent ( ) } ) ) ; } } ) ; return Promise . all ( aPromises ) ; }
Since we don't use the CommandStack here, we have to take care of the applied Changes,
 which are stored in the custom data of the control, ourselves;
 The original Change doesn't get deleted there, and therefore can't be applied again without this
Since we don ' t use the CommandStack here we have to take care of the applied Changes which are stored in the custom data of the control ourselves ; The original Change doesn ' t get deleted there and therefore can ' t be applied again without this