@@ -116,7 +116,7 @@ final class GoogleAddress extends Address
116116 *
117117 * @return GoogleAddress
118118 */
119- public function withId (string $ id = null )
119+ public function withId (string $ id = null ): GoogleAddress
120120 {
121121 $ new = clone $ this ;
122122 $ new ->id = $ id ;
@@ -139,7 +139,7 @@ public function getId()
139139 *
140140 * @return GoogleAddress
141141 */
142- public function withLocationType (string $ locationType = null )
142+ public function withLocationType (string $ locationType = null ): GoogleAddress
143143 {
144144 $ new = clone $ this ;
145145 $ new ->locationType = $ locationType ;
@@ -168,7 +168,7 @@ public function getResultType(): array
168168 *
169169 * @return GoogleAddress
170170 */
171- public function withResultType (array $ resultType )
171+ public function withResultType (array $ resultType ): GoogleAddress
172172 {
173173 $ new = clone $ this ;
174174 $ new ->resultType = $ resultType ;
@@ -189,7 +189,7 @@ public function getFormattedAddress()
189189 *
190190 * @return GoogleAddress
191191 */
192- public function withFormattedAddress (string $ formattedAddress = null )
192+ public function withFormattedAddress (string $ formattedAddress = null ): GoogleAddress
193193 {
194194 $ new = clone $ this ;
195195 $ new ->formattedAddress = $ formattedAddress ;
@@ -210,7 +210,7 @@ public function getAirport()
210210 *
211211 * @return GoogleAddress
212212 */
213- public function withAirport (string $ airport = null )
213+ public function withAirport (string $ airport = null ): GoogleAddress
214214 {
215215 $ new = clone $ this ;
216216 $ new ->airport = $ airport ;
@@ -231,7 +231,7 @@ public function getColloquialArea()
231231 *
232232 * @return GoogleAddress
233233 */
234- public function withColloquialArea (string $ colloquialArea = null )
234+ public function withColloquialArea (string $ colloquialArea = null ): GoogleAddress
235235 {
236236 $ new = clone $ this ;
237237 $ new ->colloquialArea = $ colloquialArea ;
@@ -252,7 +252,7 @@ public function getIntersection()
252252 *
253253 * @return GoogleAddress
254254 */
255- public function withIntersection (string $ intersection = null )
255+ public function withIntersection (string $ intersection = null ): GoogleAddress
256256 {
257257 $ new = clone $ this ;
258258 $ new ->intersection = $ intersection ;
@@ -273,7 +273,7 @@ public function getNaturalFeature()
273273 *
274274 * @return GoogleAddress
275275 */
276- public function withNaturalFeature (string $ naturalFeature = null )
276+ public function withNaturalFeature (string $ naturalFeature = null ): GoogleAddress
277277 {
278278 $ new = clone $ this ;
279279 $ new ->naturalFeature = $ naturalFeature ;
@@ -294,7 +294,7 @@ public function getNeighborhood()
294294 *
295295 * @return GoogleAddress
296296 */
297- public function withNeighborhood (string $ neighborhood = null )
297+ public function withNeighborhood (string $ neighborhood = null ): GoogleAddress
298298 {
299299 $ new = clone $ this ;
300300 $ new ->neighborhood = $ neighborhood ;
@@ -315,7 +315,7 @@ public function getPark()
315315 *
316316 * @return GoogleAddress
317317 */
318- public function withPark (string $ park = null )
318+ public function withPark (string $ park = null ): GoogleAddress
319319 {
320320 $ new = clone $ this ;
321321 $ new ->park = $ park ;
@@ -357,7 +357,7 @@ public function getPolitical()
357357 *
358358 * @return GoogleAddress
359359 */
360- public function withPolitical (string $ political = null )
360+ public function withPolitical (string $ political = null ): GoogleAddress
361361 {
362362 $ new = clone $ this ;
363363 $ new ->political = $ political ;
@@ -374,11 +374,11 @@ public function getPremise()
374374 }
375375
376376 /**
377- * @param null $premise
377+ * @param string $premise
378378 *
379379 * @return GoogleAddress
380380 */
381- public function withPremise (string $ premise = null )
381+ public function withPremise (string $ premise = null ): GoogleAddress
382382 {
383383 $ new = clone $ this ;
384384 $ new ->premise = $ premise ;
@@ -399,7 +399,7 @@ public function getStreetAddress()
399399 *
400400 * @return GoogleAddress
401401 */
402- public function withStreetAddress (string $ streetAddress = null )
402+ public function withStreetAddress (string $ streetAddress = null ): GoogleAddress
403403 {
404404 $ new = clone $ this ;
405405 $ new ->streetAddress = $ streetAddress ;
@@ -420,7 +420,7 @@ public function getSubpremise()
420420 *
421421 * @return GoogleAddress
422422 */
423- public function withSubpremise (string $ subpremise = null )
423+ public function withSubpremise (string $ subpremise = null ): GoogleAddress
424424 {
425425 $ new = clone $ this ;
426426 $ new ->subpremise = $ subpremise ;
@@ -441,7 +441,7 @@ public function getWard()
441441 *
442442 * @return GoogleAddress
443443 */
444- public function withWard (string $ ward = null )
444+ public function withWard (string $ ward = null ): GoogleAddress
445445 {
446446 $ new = clone $ this ;
447447 $ new ->ward = $ ward ;
@@ -462,7 +462,7 @@ public function getEstablishment()
462462 *
463463 * @return GoogleAddress
464464 */
465- public function withEstablishment (string $ establishment = null )
465+ public function withEstablishment (string $ establishment = null ): GoogleAddress
466466 {
467467 $ new = clone $ this ;
468468 $ new ->establishment = $ establishment ;
@@ -473,7 +473,7 @@ public function withEstablishment(string $establishment = null)
473473 /**
474474 * @return AdminLevelCollection
475475 */
476- public function getSubLocalityLevels ()
476+ public function getSubLocalityLevels (): AdminLevelCollection
477477 {
478478 return $ this ->subLocalityLevels ;
479479 }
@@ -483,15 +483,15 @@ public function getSubLocalityLevels()
483483 *
484484 * @return $this
485485 */
486- public function withSubLocalityLevels (array $ subLocalityLevel )
486+ public function withSubLocalityLevels (array $ subLocalityLevel ): GoogleAddress
487487 {
488488 $ subLocalityLevels = [];
489489 foreach ($ subLocalityLevel as $ level ) {
490490 if (empty ($ level ['level ' ])) {
491491 continue ;
492492 }
493493
494- $ name = $ level ['name ' ] ?? $ level ['code ' ] ?? null ;
494+ $ name = $ level ['name ' ] ?? $ level ['code ' ] ?? '' ;
495495 if (empty ($ name )) {
496496 continue ;
497497 }
0 commit comments