Skip to content

Commit

Permalink
Merge branch 'hotfix/1.0.2'
Browse files Browse the repository at this point in the history
  • Loading branch information
polosson committed Dec 10, 2024
2 parents a0cad88 + c8f963d commit ebef89e
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ Tous les changements notables sur le projet sont documentés dans ce fichier.

Ce projet adhère au principe du [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## 1.0.2 (2024-12-10)

- Corrige l'étape 3 de l'assistant d'installation.

## 1.0.1 (2024-12-09)

- Corrige un problème avec l'affichage des remises de matériel dans les devis et factures.
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.0.1
1.0.2
4 changes: 2 additions & 2 deletions server/src/App/Controllers/SetupController.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
use Loxya\Errors\Exception\ValidationException;
use Loxya\Http\Request;
use Loxya\Models\Category;
use Loxya\Models\Country;
use Loxya\Models\Enums\Group;
use Loxya\Models\User;
use Loxya\Services\I18n;
Expand Down Expand Up @@ -293,7 +292,8 @@ private function _validateCompanyData($companyData): void
new Rule\Key('country', V::custom(
static function ($value) {
V::notEmpty()->stringType()->check($value);
return Country::where('code', $value)->exists();
$allCountries = array_column(Install::getAllCountries(), 'code');
return in_array($value, $allCountries, true);
},
)),
);
Expand Down

0 comments on commit ebef89e

Please sign in to comment.