There is a famous problem that we can prove that if $P=NP$, then any non-trivial language $A \in P$ is NP- complete.
The proof idea was to use non- triviality of $A$. So we say that as $A$ is non-trivial, there exist $x \in A$ and $y \notin A$. Now for an arbitrary NP language $B$, we define the reduction function from $B$ to $A$ as $f(w)= x$, if $w\in B$ and $f(w)= y$, if $w \notin B$.
This function is clearly a reduction from $B$ to $A$.
But my problem is that how we used the assumption $P=NP$ or why we needed it?