@@ -37,14 +37,12 @@ public function getOrderDetails()
3737 {
3838 $ request = $ this ->getRequest ();
3939 $ module = $ request ->getModuleName ();
40- $ controller = $ request ->getControllerName ();
4140 $ action = $ request ->getActionName ();
4241 $ cart = Mage::getSingleton ('checkout/session ' );
4342
44- $ quote_id = $ cart-> getQuoteId ();
43+ //Only tag shopping cart pages.
4544 if ($ module == 'checkout ' ) {
4645 Mage::log ("Getting order details for checkout " );
47- $ orderId = $ cart ->getLastOrderId ();
4846 $ lastOrderId = Mage::getSingleton ('checkout/session ' )
4947 ->getLastRealOrderId ();
5048 $ orderId = Mage::getModel ('sales/order ' )
@@ -66,7 +64,7 @@ public function getOrderDetails()
6664 return $ orderDet ;
6765 }
6866
69- Mage::log ("Not in a cart module. No need to tag order details " );
67+ Mage::log ("Not in a cart module. No need to show order details " );
7068
7169 }
7270
@@ -116,10 +114,11 @@ public function getCartItems()
116114 {
117115 $ request = $ this ->getRequest ();
118116 $ module = $ request ->getModuleName ();
119- $ controller = $ request ->getControllerName ();
120- $ action = $ request ->getActionName ();
121117 $ cart = Mage::getSingleton ('checkout/session ' );
118+
122119 $ product = array ();
120+
121+ //Only tag on checkout pages.
123122 if ($ module == 'checkout ' ) {
124123 Mage::log ("Getting cart items for a checkout " );
125124 $ orderId = $ cart ->getLastOrderId ();
0 commit comments