Hi,

On 14.07.20 10:51, Ilija Tovilo wrote:
Would this still work together with short-circuiting and the null
coalesce operator?

$country = $session?->user?->getAddress()?->country ?? 'defaultCountry';

Yes, your example will still work, this is solely about references :)

Thanks for clarifying, that's fantastic :)

- Markus

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: https://www.php.net/unsub.php

Reply via email to