@@ -40,8 +40,8 @@ public function __construct()
4040 {
4141 $ this ->name = 'ps_googleanalytics ' ;
4242 $ this ->tab = 'analytics_stats ' ;
43- $ this ->version = '3.0.0 ' ;
44- $ this ->ps_versions_compliancy = array ('min ' => '1.7.1 .0 ' , 'max ' => _PS_VERSION_ );
43+ $ this ->version = '3.0.1 ' ;
44+ $ this ->ps_versions_compliancy = array ('min ' => '1.7.0 .0 ' , 'max ' => _PS_VERSION_ );
4545 $ this ->author = 'PrestaShop ' ;
4646 $ this ->module_key = 'fd2aaefea84ac1bb512e6f1878d990b8 ' ;
4747 $ this ->bootstrap = true ;
@@ -320,7 +320,7 @@ public function hookdisplayFooter()
320320 if (isset ($ this ->context ->cookie ->ga_cart )) {
321321 $ this ->filterable = 0 ;
322322
323- $ gacarts = unserialize ($ this ->context ->cookie ->ga_cart );
323+ $ gacarts = Tools:: jsonDecode ($ this ->context ->cookie ->ga_cart );
324324 foreach ($ gacarts as $ gacart ) {
325325 if ($ gacart ['quantity ' ] > 0 ) {
326326 $ ga_scripts .= 'MBG.addToCart( ' .Tools::jsonEncode ($ gacart ).'); ' ;
@@ -771,7 +771,7 @@ public function hookactionCartSave()
771771 }
772772
773773 if (isset ($ this ->context ->cookie ->ga_cart )) {
774- $ gacart = unserialize ($ this ->context ->cookie ->ga_cart );
774+ $ gacart = Tools:: jsonDecode ($ this ->context ->cookie ->ga_cart );
775775 } else {
776776 $ gacart = array ();
777777 }
@@ -791,7 +791,7 @@ public function hookactionCartSave()
791791 }
792792
793793 $ gacart [$ id_product ] = $ ga_products ;
794- $ this ->context ->cookie ->ga_cart = serialize ($ gacart );
794+ $ this ->context ->cookie ->ga_cart = Tools:: jsonEncode ($ gacart );
795795 }
796796 }
797797
0 commit comments