original_string: protected function prepareCart(array &$cart)
      {
          if (!empty($cart['items'])) {
  
              foreach ($cart['items'] as &$item) {
                  $item['currency'] = $cart['currency'];
                  $this->prepareCartItem($item);
              }
  
              $this->setItemTotalFormatted($cart, $this->price);
          }
      }
code: protected function prepareCart(array &$cart)
      {
          if (!empty($cart['items'])) {
  
              foreach ($cart['items'] as &$item) {
                  $item['currency'] = $cart['currency'];
                  $this->prepareCartItem($item);
              }
  
              $this->setItemTotalFormatted($cart, $this->price);
          }
      }
code_tokens: protected function prepareCart ( array & $ cart ) { if ( ! empty ( $ cart [ 'items' ] ) ) { foreach ( $ cart [ 'items' ] as & $ item ) { $ item [ 'currency' ] = $ cart [ 'currency' ] ; $ this -> prepareCartItem ( $ item ) ; } $ this -> setItemTotalFormatted ( $ cart , $ this -> price ) ; } }
docstring: Prepares an array of cart items
  @param array $cart
docstring_tokens: Prepares an array of cart items