File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed
app/code/Magento/Directory/Model Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -96,16 +96,17 @@ public function getCountryInfo($countryId)
96
96
$ store ->getCode ()
97
97
);
98
98
99
- $ countries = $ this ->directoryHelper ->getCountryCollection ($ store )->addCountryIdFilter ($ countryId )->load ();
100
- if ($ countries ->count () == 0 ) {
99
+ $ countriesCollection = $ this ->directoryHelper ->getCountryCollection ($ store )->load ();
100
+
101
+ if ($ countriesCollection ->count () == 0 ) {
101
102
throw new NoSuchEntityException (
102
103
__ (
103
104
'Requested country is not available. '
104
105
)
105
106
);
106
107
}
107
108
$ regions = $ this ->directoryHelper ->getRegionData ();
108
- $ country = $ countries ->getItemById ($ countryId );
109
+ $ country = $ countriesCollection ->getItemById ($ countryId );
109
110
$ countryInfo = $ this ->setCountryInfo ($ country , $ regions , $ storeLocale );
110
111
111
112
return $ countryInfo ;
You can’t perform that action at this time.
0 commit comments