Open betterapp opened 7 months ago
@BlackbitDevs ??
$object
can only be null if the pimcore.dataobject.postUpdate
or pimcore.dataobject.postAdd
event gets called without an object. This sounds strange to me, especially because nowadays this is not even possible due to the return type of https://github.com/pimcore/pimcore/blob/177a8604c06831da6bb5889931342512659fef53/lib/Event/Model/ElementEventInterface.php#L23
But you are right that it should be checked if $object is an instance of ElementInterface
, especially fpr Picmore versions where getElement()
could return null
.
Have fixed this in 3.6.6
Btw: Helper::getUser()
will always return a user. If we cannot find a logged-in user, the system
user gets returned.
We have a project that use third-party import/export solution When I installed DataDirector and use old import I get such error in logs:
It should be checked if $object is empty then should not run command