Skip to content

Commit d665cad

Browse files
Address code review feedback: improve exception handling and consistency
Co-authored-by: dpfaffenbauer <5981845+dpfaffenbauer@users.noreply.github.com>
1 parent dc266d5 commit d665cad

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/CoreShop/Bundle/CoreBundle/Command/SetupStatesCommand.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ protected function execute(InputInterface $input, OutputInterface $output): int
105105
try {
106106
$rinvexCountry = CountryLoader::country($countryCode);
107107
} catch (\Exception $e) {
108-
$io->warning(sprintf('Country data not found for code "%s" in Rinvex data.', $countryCode));
108+
$io->warning(sprintf('Country data not found for code "%s" in Rinvex data: %s', $countryCode, $e->getMessage()));
109109

110110
continue;
111111
}
@@ -129,7 +129,7 @@ protected function execute(InputInterface $input, OutputInterface $output): int
129129
}
130130

131131
foreach ($divisions as $isoCode => $division) {
132-
if (empty($division['name'])) {
132+
if (!$division['name']) {
133133
continue;
134134
}
135135

0 commit comments

Comments
 (0)