String (@NotNull Collection<? extends AbstractVcs> vcses) { String operationName = null; for (AbstractVcs vcs : vcses) { final RollbackEnvironment rollbackEnvironment = vcs.getRollbackEnvironment(); if (rollbackEnvironment != null) { if (operationName == null) { operationName = rollbackEnvironment.getRollbackOperationName(); } else if (!operationName.equals(rollbackEnvironment.getRollbackOperationName())) { // if there are different names, use default return DefaultRollbackEnvironment.getRollbackOperationText(); } } } return operationName != null ? operationName : DefaultRollbackEnvironment.getRollbackOperationText(); }