Fix: initialize countries

This commit is contained in:
philipp lang 2021-04-10 00:38:27 +02:00
parent f82b4a2920
commit 5f4f7fd72c
1 changed files with 2 additions and 2 deletions

View File

@ -14,8 +14,8 @@ class InitializeCountries {
public function handle() {
$this->bar->task('Synchronisiere Länder', function() {
collect($this->api->countries()->data)->each(function($nationality) {
\App\Country::create(['nami_id' => $nationality->id, 'name' => $nationality->descriptor]);
$this->api->countries()->each(function($country) {
\App\Country::create(['nami_id' => $country->id, 'name' => $country->name]);
});
});
}