Solved a quartic equation by dividing
The reason why, in general, it is considered bad practice to divide by a variable, is because you may lose out on solutions, when whatever you divide by happens to be zero. It is however perfectly valid if you can ensure you are dividing by a nonzero quantity.
For example: solving $x(x-1)=x(2x-3)$. Naively one might divide by $x$ on both sides, and get that $x-1=2x-3\implies x=2$. However they would be implicitly assuming that $x\neq0$ (as you cannot divide by zero). One way to deal with this, for this example, is to bring all terms onto the same side and factor (which is usually prefered), however it would be equally valid to consider two cases instead.
Case 1: $x=0$. In this case, the equation is satisfied, so we have a valid solution.
Case 2: $x\neq0$. In this case, we can divide both sides by $x$, because it is nonzero, and proceed as before.
So in general, if it is inconvenient to factor, you can just consider the two cases when what you want to divide by is zero, and when it is nonzero. In your case, it is pretty easy to check that $x=0$ does not satisfy the equation, so it is perfectly valid to divide by the variable $x$ in this case, without any additional casework.