Is the following solution correct? Question: $ \sqrt{x^2 + 1} + \frac{8}{\sqrt{x^2 + 1}} = \sqrt{x^2 + 9}$
My solution: $(x^2 + 1) + 8 = \sqrt{x^2 + 9} \sqrt{x^2 + 1}$
$=> (x^2 + 9) = \sqrt{x^2 + 9} \sqrt{x^2 + 1}$
$=> (x^2 + 9) - \sqrt{x^2 + 9} \sqrt{x^2 + 1} = 0$
$=> \sqrt{x^2 + 9} (\sqrt{x^2 + 9} - \sqrt{x^2 + 1}) = 0$
So, either $\sqrt{x^2 + 9} = 0$ or $(\sqrt{x^2 + 9} - \sqrt{x^2 + 1}) = 0$
From the first expression, I get $x = \pm 3 i$ and from the second expression, I get nothing.
Now, notice how in the 2nd step, I could've divided both the sides by $\sqrt{x^2 + 9}$, but I didn't because I learned here that we must never do that and that we should always factor: Why one should never divide by an expression that contains a variable.
So, my question is: is the solution above correct? Would it have been any harm had I divided both the sides by $\sqrt{x^2 + 9}$?

A suggested simplification. You should always look for simplifications to the algebra if they're easy to find.
Let $y = x^2 + 1$
Then you're solving $\sqrt y + \frac{8}{\sqrt y} = \sqrt{y + 8}$
$\frac{y + 8}{\sqrt y} = \sqrt{y + 8}$
$(y+8)^2 = y(y+8)$
$8(y+8) = 0$
From this, it should be obvious that $y = -8$ is the only root, giving $x^2 + 1 = -8$ or $x = \pm 3i$.
