parse_url  may return false

#2260, #2261 (which are identical)
Not sure if it matters in this context, but the elvis operator doesn't use a strict comparator.

http://php.net/manual/en/language.operators.comparison.php#language.operators.comparison.ternary