3 namespace Wallabag\CoreBundle\Helper
;
5 use Doctrine\ORM\Mapping
as ORM
;
8 * Trait to handle created & updated date of an Entity.
10 trait EntityTimestampsTrait
16 public function timestamps()
18 if (null === $this->createdAt
) {
19 $this->createdAt
= new \
DateTime();
22 $this->updatedAt
= new \
DateTime();