Skip to content

Commit

Permalink
Fixed scrutinizer-ci issues
Browse files Browse the repository at this point in the history
  • Loading branch information
aimeos committed Mar 8, 2019
1 parent 377249d commit 2b406db
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
5 changes: 1 addition & 4 deletions controller/frontend/src/Controller/Frontend/Basket/Base.php
Expand Up @@ -20,9 +20,6 @@
*/
abstract class Base extends \Aimeos\Controller\Frontend\Base implements Iface
{
private $listTypeItems = [];


/**
* Calculates and returns the current price for the given order product and product prices.
*
Expand Down Expand Up @@ -60,7 +57,7 @@ protected function calcPrice( \Aimeos\MShop\Order\Item\Base\Product\Iface $produ
}

$orderAttributes = $product->getAttributeItems();
$attrItems = $this->getAttributeItems( $orderAttributes, ['price'] );
$attrItems = $this->getAttributeItems( $orderAttributes );

// add prices of (optional) attributes
foreach( $orderAttributes as $orderAttrItem )
Expand Down
Expand Up @@ -285,7 +285,7 @@ public function updateProduct( $position, $quantity )
$productItem = $manager->findItem( $product->getProductCode(), array( 'price', 'text' ), true );

$price = $this->calcPrice( $product, $productItem->getRefItems( 'price', 'default' ), $quantity );
$product = $product->setQuantity( $quantity )->setPrice( $price, $quantity );
$product = $product->setQuantity( $quantity )->setPrice( $price );

$this->baskets[$this->type] = $this->get()->addProduct( $product, $position );
return $this->save();
Expand Down

0 comments on commit 2b406db

Please sign in to comment.