I'm using the definition of the one dimensional dirac-delta function, $\delta(x)$, being, $$\int_{-\infty}^{+\infty}\delta(x)f(x)dx = f(0) \tag1$$ and I'm doing a question which asks me to (via ordinary integral manipulations) show that, for $a \in \mathbb{R}$, $$\delta(ax)=\frac{1}{|a|}\delta(x).\tag2$$ The solution said to use substitution of $u=|a|x$ and $du=|a|dx$ to get $$\int_{-\infty}^{+\infty}\delta(ax)f(x)dx = \frac{1}{|a|}\int_{-\infty}^{+\infty}\delta(\pm u)f\biggl(\frac{u}{|a|}\biggl) du= \frac{1}{|a|}f(0) \tag3.$$ And then by equating the LHS of $(3)$ with with the LHS of $(1)$ we get the identity in $(2)$. That makes sense. Only thing is I don't get why one would have used the substitution, $u=|a|x$, as opposed to the seemingly more natural, $u=ax.$ Can anybody tell me why they did that in the solution? The short answer is because that is what gets the correct answer. But the identity in $(2)$ seems to be a major/common one of the Dirac Delta function, which seems to imply that, $$\delta(ax)=\frac{1}{a}\delta(x),$$ doesn't hold for negative $a$. If that is the case can someone explain why?
I hope my question is clear.