Skip to content
Draft
Changes from 1 commit
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
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
Prev Previous commit
Next Next commit
Refactor Meta object
  • Loading branch information
Art4 committed Jul 19, 2024
commit f5e37be54bd9660971e367ae41d0e9f7d53e037d
8 changes: 1 addition & 7 deletions src/V1/Meta.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,7 @@ protected function parse(mixed $object): void
throw new ValidationException('Meta has to be an object, "' . gettype($object) . '" given.');
}

$object_vars = get_object_vars($object);

if (count($object_vars) === 0) {
return;
}

foreach ($object_vars as $name => $value) {
foreach (get_object_vars($object) as $name => $value) {
$this->set($name, $value);
}
}
Expand Down