File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
app/code/Magento/QuoteGraphQl/Model/Cart Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change 7
7
8
8
namespace Magento \QuoteGraphQl \Model \Cart ;
9
9
10
+ use Magento \Framework \App \ObjectManager ;
10
11
use Magento \Framework \GraphQl \Exception \GraphQlInputException ;
11
12
use Magento \GraphQl \Model \Query \ContextInterface ;
12
13
use Magento \Quote \Api \Data \CartInterface ;
@@ -35,16 +36,17 @@ class SetShippingAddressesOnCart implements SetShippingAddressesOnCartInterface
35
36
/**
36
37
* @param AssignShippingAddressToCart $assignShippingAddressToCart
37
38
* @param GetShippingAddress $getShippingAddress
38
- * @param QuoteRepository $quoteRepository
39
+ * @param QuoteRepository|null $quoteRepository
39
40
*/
40
41
public function __construct (
41
42
AssignShippingAddressToCart $ assignShippingAddressToCart ,
42
43
GetShippingAddress $ getShippingAddress ,
43
- QuoteRepository $ quoteRepository
44
+ QuoteRepository $ quoteRepository = null
44
45
) {
45
46
$ this ->assignShippingAddressToCart = $ assignShippingAddressToCart ;
46
47
$ this ->getShippingAddress = $ getShippingAddress ;
47
- $ this ->quoteRepository = $ quoteRepository ;
48
+ $ this ->quoteRepository = $ quoteRepository
49
+ ?? ObjectManager::getInstance ()->get (QuoteRepository::class);
48
50
}
49
51
50
52
/**
You can’t perform that action at this time.
0 commit comments