iterate in $data until fields for empty relation are over
soko-web/pipeline/pr-master This commit looks good

This commit is contained in:
bence authored and bence committed 2023-05-28 15:47:35 +02:00
1 parent dd855a6d6b
commit da2801560d
1 file changed
+3
@@ -278,7 +278,10 @@ class PersistentDataManager implements IPersistentDataManager
$method = 'set' . str_replace('_', '', ucwords($relation, '_')); $method = 'set' . str_replace('_', '', ucwords($relation, '_'));
$model->$method($relationModel); $model->$method($relationModel);
} else { } else {
while (substr($key, 0, strlen($relation . '__')) === $relation . '__') {
next($data); next($data);
$key = key($data);
}
} }
next($relations); next($relations);