diff --git a/src/package/Data/Repository.php b/src/package/Data/Repository.php index 0887b901..7759a076 100644 --- a/src/package/Data/Repository.php +++ b/src/package/Data/Repository.php @@ -2,6 +2,7 @@ namespace PragmaRX\Countries\Package\Data; +use IlluminateAgnostic\Str\Support\Str; use PragmaRX\Countries\Package\Services\Helper; use PragmaRX\Countries\Package\Services\Hydrator; use Psr\SimpleCache\CacheInterface as CacheContract; @@ -148,7 +149,7 @@ public function loadCountries() $this->countriesJson = $this->loadCountriesJson(); $overload = $this->helper->loadJsonFiles($this->helper->dataDir('countries/overload'))->mapWithKeys(function ($country, $code) { - return [upper($code) => $country]; + return [Str::upper($code) => $country]; }); $this->countriesJson = $this->countriesJson->overwrite($overload); @@ -207,11 +208,11 @@ public function all() public function currencies() { $currencies = $this->helper->loadJsonFiles($this->helper->dataDir('currencies/default'))->mapWithKeys(function ($country, $code) { - return [upper($code) => $country]; + return [Str::upper($code) => $country]; }); $overload = $this->helper->loadJsonFiles($this->helper->dataDir('currencies/overload'))->mapWithKeys(function ($country, $code) { - return [upper($code) => $country]; + return [Str::upper($code) => $country]; }); return $currencies->overwrite($overload);