File tree Expand file tree Collapse file tree 3 files changed +9
-11
lines changed
app/code/Magento/CatalogInventoryGraphQl/Model Expand file tree Collapse file tree 3 files changed +9
-11
lines changed Original file line number Diff line number Diff line change 77
88namespace Magento \CatalogInventoryGraphQl \Model \Resolver ;
99
10- use Magento \Framework \GraphQl \Query \Resolver \ContextInterface ;
1110use Magento \Framework \GraphQl \Schema \Type \ResolveInfo ;
1211use Magento \Framework \GraphQl \Config \Element \Field ;
1312use Magento \Framework \GraphQl \Query \ResolverInterface ;
@@ -38,12 +37,12 @@ public function __construct(
3837 */
3938 public function resolve (
4039 Field $ field ,
41- ContextInterface $ context ,
40+ $ context ,
4241 ResolveInfo $ info ,
43- ?array $ value ,
44- ?array $ args
42+ ?array $ value = null ,
43+ ?array $ args = null
4544 ) {
4645 $ stockItem = $ this ->stockItemService ->getStockItem ($ value ['model ' ]);
47- return $ stockItem ? $ stockItem ->getMaxSaleQty () : null ;
46+ return $ stockItem? ->getMaxSaleQty();
4847 }
4948}
Original file line number Diff line number Diff line change 77
88namespace Magento \CatalogInventoryGraphQl \Model \Resolver ;
99
10- use Magento \Framework \GraphQl \Query \Resolver \ContextInterface ;
1110use Magento \Framework \GraphQl \Schema \Type \ResolveInfo ;
1211use Magento \Framework \GraphQl \Config \Element \Field ;
1312use Magento \Framework \GraphQl \Query \ResolverInterface ;
@@ -38,12 +37,12 @@ public function __construct(
3837 */
3938 public function resolve (
4039 Field $ field ,
41- ContextInterface $ context ,
40+ $ context ,
4241 ResolveInfo $ info ,
43- ?array $ value ,
44- ?array $ args
42+ ?array $ value = null ,
43+ ?array $ args = null
4544 ) {
4645 $ stockItem = $ this ->stockItemService ->getStockItem ($ value ['model ' ]);
47- return $ stockItem ? $ stockItem ->getMinSaleQty () : null ;
46+ return $ stockItem? ->getMinSaleQty();
4847 }
4948}
Original file line number Diff line number Diff line change @@ -49,7 +49,7 @@ public function __construct(
4949 * Returns stock item if the product is available
5050 *
5151 * @param Product|null $product
52- * @return Item
52+ * @return Item|null
5353 */
5454 public function getStockItem (?Product $ product )
5555 {
You can’t perform that action at this time.
0 commit comments