TypeError at App\Model\Database\Entity\User::getLastLoggedAt()
vanam opened this issue · comments
Martin Váňa commented
TypeError
App\Model\Database\Entity\User::getLastLoggedAt(): Return value must be of type ?App\Model\Utils\DateTime, DateTime returned
Exactly the same works at https://github.com/contributte/webapp-skeleton/blob/master/app/model/Database/Entity/User.php
I am missing what is different.
How to reproduce:
- Set
lastLoggedAt
to a random user.
Workaround is to set dates to build-in \DateTime
type.
Martin Váňa commented
One possible solution is to use \DateTimeInterface
.
Milan Felix Šulc commented
That's really weird.
Michal Bachtin commented
Same issue here. Installed skeleton via Composer with local DB (manually run the Migration script).