Run Rector on your code to see what it can do for you:
{ public function undefinedVarAfter() { - if ($a = $this->methodX()) { - $this->out = $a; - } else { - $this->out = $this->methodY(); - } + $this->out = $a = $this->methodX() ? $a : $this->methodY(); } }
Applied Rules:
Not a change you expect?
rector.php