Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dev to main #139

Merged
merged 3 commits into from
Jan 17, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions lib/Service/ObjectService.php
Original file line number Diff line number Diff line change
Expand Up @@ -725,7 +725,7 @@ private function addObject(
// Handle nested object in array
$nestedObject = $this->saveObject(
register: $register,
schema: $subSchema,
schema: (int) $subSchema,
object: $item,
depth: $depth-1
);
Expand Down Expand Up @@ -834,7 +834,7 @@ private function handleArrayProperty(
return $items;
}

if ($property['items']['type'] === 'file') {
if (isset($property['items']['type']) === true && $property['items']['type'] === 'file') {
foreach ($items as $index => $item) {
$items[$index] = $this->handleFileProperty(
objectEntity: $objectEntity,
Expand Down Expand Up @@ -972,6 +972,10 @@ private function handleProperty(
int $depth = 0
): array
{
if (isset($property['type']) === false) {
return $object;
}

switch($property['type']) {
case 'object':
$object[$propertyName] = $this->handleObjectProperty(
Expand Down
Loading