Sorry for confusion.
I am in the process of solving a functional equation, I need to show injectivity. (By the way i know that it is injective, I'm trying to prove it to myself).
Putting $f(x)=f(y)$ yields $x(f(x)-1)=y(f(x)-1)$. To obtain $x=y$, and thus show injectivity, I need to divide by $f(x)-1$, which is only allowed if $f(x)\not=1$. Is the function injective?
Depends on $f$. It is certainly true for the obviously not injective $f$: $$f(x)=\begin{cases}x&x\in\Bbb Q\\1&x\notin\Bbb Q\end{cases}$$