Skip to content

Commit

Permalink
Issue magento#18094: Should getQty() return int/float or string
Browse files Browse the repository at this point in the history
 - remove typecasting from the setter
  • Loading branch information
Oleksii Korshenko authored Oct 19, 2018
1 parent 3fc107a commit fa52936
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/code/Magento/Catalog/Model/Product.php
Original file line number Diff line number Diff line change
Expand Up @@ -972,7 +972,7 @@ public function afterSave()
public function setQty($qty)
{
if ($this->getData('qty') != $qty) {
$this->setData('qty', (float)$qty);
$this->setData('qty', $qty);
$this->reloadPriceInfo();
}
return $this;
Expand Down

0 comments on commit fa52936

Please sign in to comment.