Skip to content

Commit

Permalink
Merge pull request #58 from jeremycr/fix_date
Browse files Browse the repository at this point in the history
Correctly map creation and modification dates in collections #57
  • Loading branch information
MarioBlazek authored Mar 16, 2020
2 parents 6feb831 + 6d268fe commit 7e5ca4d
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions lib/Core/Mapper/DomainObjectMapper.php
Original file line number Diff line number Diff line change
Expand Up @@ -128,9 +128,6 @@ private function getUser($userId)

private function getDateTime(int $timestamp): DateTimeInterface
{
$date = new DateTimeImmutable();
$date->setTimestamp($timestamp);

return $date;
return DateTimeImmutable::createFromFormat('U', (string) $timestamp);
}
}

0 comments on commit 7e5ca4d

Please sign in to comment.