Closed tobi-pb closed 6 years ago
https://github.com/mash2/cobby-magento2/blob/dfea5dcc3a7a9fe550519a59fb11df34f62faeed/Model/ProductManagement.php#L91
$factory = $this->productFactory->create();
I think productFactory->create creates an product, not a factory. So could be nice to rename $factory to $product.
$product = $factory->load($productId);
In this case $product und $factory referencing same object, aren't they? Would be great to rename factory to product and just use it
$product->load($productId);
solved with commit 159e63a
https://github.com/mash2/cobby-magento2/blob/dfea5dcc3a7a9fe550519a59fb11df34f62faeed/Model/ProductManagement.php#L91
I think productFactory->create creates an product, not a factory. So could be nice to rename $factory to $product.
In this case $product und $factory referencing same object, aren't they? Would be great to rename factory to product and just use it