Skip to content

Commit fa840b6

Browse files
authored
🚨 Apply PHP CS Fixer fixes (#1219)
1 parent fab0c83 commit fa840b6

File tree

3 files changed

+14
-14
lines changed

3 files changed

+14
-14
lines changed

‎Geonames.php‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ public function reverseQuery(ReverseQuery $query): Collection
9494
/**
9595
* @return CountryInfo[]
9696
*/
97-
public function getCountryInfo(string $country = null, string $locale = null): array
97+
public function getCountryInfo(?string $country = null, ?string $locale = null): array
9898
{
9999
$url = sprintf(self::BASE_ENDPOINT_URL, 'countryInfoJSON', $this->username);
100100

@@ -154,7 +154,7 @@ public function getName(): string
154154
return 'geonames';
155155
}
156156

157-
private function executeQuery(string $url, string $locale = null): AddressCollection
157+
private function executeQuery(string $url, ?string $locale = null): AddressCollection
158158
{
159159
if (null !== $locale) {
160160
// Locale code transformation: for example from it_IT to it

‎Model/CountryInfo.php‎

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ public function getContinent()
119119
return $this->continent;
120120
}
121121

122-
public function withContinent(string $continent = null): self
122+
public function withContinent(?string $continent = null): self
123123
{
124124
$new = clone $this;
125125
$new->continent = $continent;
@@ -135,7 +135,7 @@ public function getCapital()
135135
return $this->capital;
136136
}
137137

138-
public function withCapital(string $capital = null): self
138+
public function withCapital(?string $capital = null): self
139139
{
140140
$new = clone $this;
141141
$new->capital = $capital;
@@ -167,7 +167,7 @@ public function getGeonameId()
167167
return $this->geonameId;
168168
}
169169

170-
public function withGeonameId(int $geonameId = null): self
170+
public function withGeonameId(?int $geonameId = null): self
171171
{
172172
$new = clone $this;
173173
$new->geonameId = null === $geonameId ? null : (int) $geonameId;
@@ -183,7 +183,7 @@ public function getIsoAlpha3()
183183
return $this->isoAlpha3;
184184
}
185185

186-
public function withIsoAlpha3(string $isoAlpha3 = null): self
186+
public function withIsoAlpha3(?string $isoAlpha3 = null): self
187187
{
188188
$new = clone $this;
189189
$new->isoAlpha3 = $isoAlpha3;
@@ -199,7 +199,7 @@ public function getFipsCode()
199199
return $this->fipsCode;
200200
}
201201

202-
public function withFipsCode(string $fipsCode = null): self
202+
public function withFipsCode(?string $fipsCode = null): self
203203
{
204204
$new = clone $this;
205205
$new->fipsCode = $fipsCode;
@@ -234,7 +234,7 @@ public function getIsoNumeric()
234234
return $this->isoNumeric;
235235
}
236236

237-
public function withIsoNumeric(string $isoNumeric = null): self
237+
public function withIsoNumeric(?string $isoNumeric = null): self
238238
{
239239
$new = clone $this;
240240
$new->isoNumeric = null === $isoNumeric ? null : (int) $isoNumeric;
@@ -250,7 +250,7 @@ public function getAreaInSqKm()
250250
return $this->areaInSqKm;
251251
}
252252

253-
public function withAreaInSqKm(string $areaInSqKm = null): self
253+
public function withAreaInSqKm(?string $areaInSqKm = null): self
254254
{
255255
$new = clone $this;
256256
$new->areaInSqKm = null === $areaInSqKm ? null : (float) $areaInSqKm;
@@ -266,7 +266,7 @@ public function getCountryCode()
266266
return $this->countryCode;
267267
}
268268

269-
public function withCountryCode(string $countryCode = null): self
269+
public function withCountryCode(?string $countryCode = null): self
270270
{
271271
$new = clone $this;
272272
$new->countryCode = $countryCode;
@@ -282,7 +282,7 @@ public function getCountryName()
282282
return $this->countryName;
283283
}
284284

285-
public function withCountryName(string $countryName = null): self
285+
public function withCountryName(?string $countryName = null): self
286286
{
287287
$new = clone $this;
288288
$new->countryName = $countryName;
@@ -298,7 +298,7 @@ public function getContinentName()
298298
return $this->continentName;
299299
}
300300

301-
public function withContinentName(string $continentName = null): self
301+
public function withContinentName(?string $continentName = null): self
302302
{
303303
$new = clone $this;
304304
$new->continentName = $continentName;
@@ -314,7 +314,7 @@ public function getCurrencyCode()
314314
return $this->currencyCode;
315315
}
316316

317-
public function withCurrencyCode(string $currencyCode = null): self
317+
public function withCurrencyCode(?string $currencyCode = null): self
318318
{
319319
$new = clone $this;
320320
$new->currencyCode = $currencyCode;

‎Model/GeonamesAddress.php‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ public function getName()
6666
return $this->name;
6767
}
6868

69-
public function withName(string $name = null): self
69+
public function withName(?string $name = null): self
7070
{
7171
$new = clone $this;
7272
$new->name = $name;

0 commit comments

Comments
 (0)