Is there any way to do this in one line?
$arr = $foo->getBarArray();
return $arr[0];
This throws an error:
return $foo->getBarArray()[0];
Is there any way to do this in one line?
$arr = $foo->getBarArray();
return $arr[0];
This throws an error:
return $foo->getBarArray()[0];