Example #1
0
 /**
  * Retrieve shipping method
  *
  * @param bool $asObject return carrier code and shipping method data as object
  * @return string|Varien_Object
  */
 public function getShippingMethod($asObject = false)
 {
     $shippingMethod = parent::getShippingMethod();
     if (!$asObject) {
         return $shippingMethod;
     } else {
         list($carrierCode, $method) = explode('_', $shippingMethod, 2);
         return new Varien_Object(array('carrier_code' => $carrierCode, 'method' => $method));
     }
 }