Nullhomotopic map extended I have troubles understanding this proof:
Let $h:S^1 \rightarrow X$ be a continuous map, then we have that if $h$ is nullhomotopic, $h$ can be extended to a continuous map $k:B^2 \rightarrow X.$
Proof: Since $h$ is nullhomotopic, there exists a homotopy $H: S^1 \times I  \rightarrow X$ between $h$ and a constant map.(This is clear). 
Now we define a map $\pi:S^1 \times I \rightarrow B^2$ by $\pi(x,t)= (1-t)x$.
Then $\pi$ is continuous, onto and closed. Now, I am not sure why we know that this map is closed.  Alright so far. Now we notice that this is a quotient map with $\pi(S^1 ,1)=0 \in B^2$ and otherwise this map is injective. It is concluded from this that we can extend $h$ to a map $k$, but it is not sad: HOW?! Does anybody know why this is possible now?

Define $k:B^2\to X$ by
$$k(x)=\begin{cases} H(\pi^{-1}(x))&\text{if }x\neq 0,\\
H(S^1,1) &\text{if }x=0.
\end{cases}$$
Note that we identify $S^1\cong \pi(S^1\times 0)=\partial B^2$. On this copy of $S^1$, $\pi(x,0)=x$. So 
$$k(x)=H(x,0)=h(x).$$
Thus $h$ extends to the map $k:B^2\to X$.
Note: It will be helpful to sketch a picture of $\pi$.
