Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 6529eb4

Browse files
committed
Tweaks
1 parent 6e85c0c commit 6529eb4

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

UPGRADE.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@ template fo render `Country` fields.
1212

1313
Starting from this EasyAdmin version, `Country` fields allow to select more
1414
than one value. That's why the type of the formatted value has changed from
15-
`?string` to `?array`. E.g. if the value of your entity property is `es`;
15+
`?string` to `?array`. E.g. if the value of your entity property is `ES`;
1616
before, `field.formattedValue` stored the string `'Spain'` and now it stores
17-
the array `['es' => 'Spain']`.
17+
the array `['ES' => 'Spain']`.
1818

1919
The country code (used to display the country flag) is now the key of the new
2020
array. Before, you had to use an internal propery called `flagCode` which has

doc/fields/CountryField.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ string conversion manually::
5050

5151
public function setCountry(?array $countryCodes): self
5252
{
53-
$this->country = null === $countryCodes : null : implode('|', $countryCodes);
53+
$this->country = null === $countryCodes ? '' : implode('|', $countryCodes);
5454

5555
return $this;
5656
}

0 commit comments

Comments
 (0)