Skip to content

Commit

Permalink
docs: add @todo
Browse files Browse the repository at this point in the history
  • Loading branch information
kenjis committed Aug 14, 2023
1 parent 366bcbe commit d82a9bb
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion system/Model.php
Original file line number Diff line number Diff line change
Expand Up @@ -799,12 +799,13 @@ protected function objectToRawArray($data, bool $onlyChanged = true, bool $recur

$primaryKey = $data->{$this->primaryKey};

// Restore Entity cast setting.
// Restore Entity casting setting.
$data->cast($cast);
}

// Always grab the primary key otherwise updates will fail.
if (
// @TODO Should use `$data instanceof Entity`.
method_exists($data, 'toRawArray')
&& (
! empty($properties)
Expand Down

0 comments on commit d82a9bb

Please sign in to comment.