File tree Expand file tree Collapse file tree 1 file changed +1
-9
lines changed
app/code/Magento/BraintreeGraphQl/Model/Resolver Expand file tree Collapse file tree 1 file changed +1
-9
lines changed Original file line number Diff line number Diff line change 21
21
*/
22
22
class CreateBraintreeClientToken implements ResolverInterface
23
23
{
24
- /**
25
- * @var StoreManagerInterface
26
- */
27
- private $ storeManager ;
28
-
29
24
/**
30
25
* @var Config
31
26
*/
@@ -37,16 +32,13 @@ class CreateBraintreeClientToken implements ResolverInterface
37
32
private $ adapterFactory ;
38
33
39
34
/**
40
- * @param StoreManagerInterface $storeManager
41
35
* @param Config $config
42
36
* @param BraintreeAdapterFactory $adapterFactory
43
37
*/
44
38
public function __construct (
45
- StoreManagerInterface $ storeManager ,
46
39
Config $ config ,
47
40
BraintreeAdapterFactory $ adapterFactory
48
41
) {
49
- $ this ->storeManager = $ storeManager ;
50
42
$ this ->config = $ config ;
51
43
$ this ->adapterFactory = $ adapterFactory ;
52
44
}
@@ -61,7 +53,7 @@ public function resolve(
61
53
array $ value = null ,
62
54
array $ args = null
63
55
) {
64
- $ storeId = $ this -> storeManager ->getStore ()->getId ();
56
+ $ storeId = ( int ) $ context -> getExtensionAttributes () ->getStore ()->getId ();
65
57
66
58
if (!$ this ->config ->isActive ($ storeId )) {
67
59
throw new GraphQlInputException (__ ('The Braintree payment method is not active. ' ));
You can’t perform that action at this time.
0 commit comments