avoid messages, if oUser is not an oxuser instance
This commit is contained in:
parent
e3b5ead1de
commit
3ef5c07478
@ -31,7 +31,7 @@ class d3_order_googleanalytics extends d3_order_googleanalytics_parent {
|
|||||||
protected function _d3SetIsNewCustomer()
|
protected function _d3SetIsNewCustomer()
|
||||||
{
|
{
|
||||||
$oUser = $this->getUser();
|
$oUser = $this->getUser();
|
||||||
$isNewCustomer = isset($oUser) ? $oUser->inGroup('oxidnotyetordered') : 0 ;
|
$isNewCustomer = (isset($oUser) && $oUser instanceof oxuser) ? $oUser->inGroup('oxidnotyetordered') : 0 ;
|
||||||
|
|
||||||
oxRegistry::getSession()->setVariable('iD3GANewCustomer', (int)$isNewCustomer);
|
oxRegistry::getSession()->setVariable('iD3GANewCustomer', (int)$isNewCustomer);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user