fixed type error in timebasedfieldupdater

This commit is contained in:
naomi 2022-06-07 12:39:22 +01:00
parent 6857bb8d4c
commit 20f2312245

View File

@ -35,7 +35,7 @@ final class TimeBasedFieldUpdater {
$this->updateEntity($id, $new_values); $this->updateEntity($id, $new_values);
} }
} }
private function updateEntity(int $entity_id, array $new_values): void { private function updateEntity(string $entity_id, array $new_values): void {
$entity = $this->entityTypeManager->getStorage($this->entity_type)->load($entity_id); $entity = $this->entityTypeManager->getStorage($this->entity_type)->load($entity_id);
foreach($new_values as $new_field=>$new_value) { foreach($new_values as $new_field=>$new_value) {
$entity->$new_field = $new_value; $entity->$new_field = $new_value;