throw new \
RuntimeException('Please provide "technicalName" to all states'
);
} if (!\
array_key_exists('de',
$state) || !\
array_key_exists('en',
$state)) { throw new \
RuntimeException('Please provide "de" and "en" translations to all states'
);
} $technicalName =
$state['technicalName'
];
$de =
$state['de'
];
$en =
$state['en'
];
$id =
$this->
getStateMachineStateIdByName($stateMachineId,
$technicalName);
if ($id) { continue;
} // state does not exist for now
$id = Uuid::
randomBytes();
$this->connection->
insert( StateMachineStateDefinition::ENTITY_NAME,
[