Looking over some old qualifying exams, we found this:
Let $A\subseteq M$ be a connected subset of a manifold $M$. If there exists a smooth retraction $r:M\longrightarrow A$, then $A$ is a submanifold.
Our thought to prove this statement was that since $r$ is smooth and the identity on $A$, then the inclusion $i:A\longrightarrow M$ is smooth. Also, since $i\circ r=\operatorname{Id}_A$, then $i_*:TA\longrightarrow TM$ is injective. Thus $i$ is a smooth immersion. Therefore $A$ is a submanifold. But, nowhere did we use that $A$ is connected. What is wrong with the argument? And, what is the correct proof?