File tree Expand file tree Collapse file tree 1 file changed +3
-6
lines changed
app/code/Magento/CatalogInventory/Block/Plugin Expand file tree Collapse file tree 1 file changed +3
-6
lines changed Original file line number Diff line number Diff line change 77
88use Magento \Catalog \Block \Product \View ;
99use Magento \CatalogInventory \Model \Product \QuantityValidator ;
10- use Magento \Framework \App \ObjectManager ;
1110
1211class ProductView
1312{
@@ -17,14 +16,12 @@ class ProductView
1716 private $ productQuantityValidator ;
1817
1918 /**
20- * @param QuantityValidator|null $productQuantityValidator
19+ * @param QuantityValidator $productQuantityValidator
2120 */
2221 public function __construct (
23- QuantityValidator $ productQuantityValidator = null
22+ QuantityValidator $ productQuantityValidator
2423 ) {
25- $ this ->productQuantityValidator = $ productQuantityValidator ?? ObjectManager::getInstance ()->get (
26- QuantityValidator::class
27- );
24+ $ this ->productQuantityValidator = $ productQuantityValidator ;
2825 }
2926
3027 /**
You can’t perform that action at this time.
0 commit comments