Micro optimization : if ($result === null)