TITLE: Statement about Homotopy in Brown's "Topology & Groupoids"
QUESTION [13 upvotes]: I am trying to understand a statement in Brown's Topology and Groupoids, 7.2.5 (Corollary 1), page 270.
Let's first have some preliminary remarks 
Let $X,Y$ be topological spaces. The track groupoid $\pi Y^X$ is defined as the groupoid whose objects are the maps $f:X\to Y$ and morphism in $\pi Y^X(f,g)$ are the homotopies $f\simeq g,$ where two homotopies $F,G$ are identified if they can be continuously deformed into each other while fixing the end maps. For $X=\{*\}$ we obtain the fundamental groupoid $\pi Y.$ A map $i:A\to X$ induces a morphism $i^*:\pi Y^X\to\pi Y^A$ by $i^*([F])=[F(i\times 1)].$
Let $i:A\to X,\ u:A\to Y.$ By $[(X,i),(Y,u)]$ we mean the set of homotopy classes of maps $f:X\to Y,fi=u,$ where a homotopy $F:f\simeq g$ is required to satisfy $F(ia,t)=ua.$ (We say $f$ and $g$ are homotopic under $i.$)

(You might want to skip this shaded part as it's probably not relevant for the particular question.):
Let $p : E → B$ be a morphism of groupoids. We say $p$ is a fibration if the
  following condition holds: for all objects $x$ of $E$ and elements $b$ in $B$ with
  initial point $px,$ there is an element $e$ of $E$ with initial point $x$ and such that $pe = b.$  
If $p : E → B$ is a morphism of groupoids and $u$ is an object of $B,$
  we write $p^{-1}[u]$ for the subgroupoid of $E$ with objects those $x$ in Ob$(E)$ such that $px = u,$ and with elements those $e$ in $E$ such that $pe = 1_u.$
Let $\pi_0G$ denote the set of components of $G.$ then we have:
Lemma 1: If $p:E\to B$ is a fibration of groupoids, then for each $b\in B(u,v)$ there is a bijection $$b_\#:\pi_0 p^{-1}[u]\to\pi_0 p^{-1}[v]$$ which respects identities and composition. Namely, if $x$ is an object with $px=u$, we assign to the component of $x$ the component of the object $y$ which is the codomain of the element $e$ such that $pe=b.$
Lemma 2: A cofibration $i:A\hookrightarrow X$ induces a fibration
  $i^*:\pi Y^X\to\pi Y^A.$
Lemma 3: Let $i:A\hookrightarrow X$ be a cofibration. Let $u:A\to Y$ be a map. Let $p=i^∗:πY^X\to πY^A.$ Then there is a canonical bijection
  $$π_0 p^{−1}[u]\cong[(X, i), (Y, u)].$$

In the proof of the Lemma 3 we use the following fact. Maybe it turns out to be useful in solving my question:  

Lemma 4: Let $i:A→X$ be a cofibration. Let $H:X\times\Bbb I→Y$ be a homotopy $f≃g,$ and let $G=H(i\times1)$ be homotopic rel end maps to $G′:u≃v.$ Then $H$ is homotopic rel end maps to some $H′:f≃g$ such that $H'(i\times 1)=G'.$

Now we can combine the three lemmas to derive the following

Corollary:  Let $i:A\hookrightarrow X$ be a cofibration and $α\in πY^A(u,v).$ Then there is a bijection $$α_\#:[(X, i), (Y, u)] → [(X, i), (Y, v)]
$$

I have figured out that this bijection works as follows:
Choose a representative $F$ of $\alpha.$ For a homotopy class $[f]$ take a representative $f:X\to Y,\ fi=u.$ The homotopy $F:u\simeq v$ on $A$ can be extended to a homotopy $G:f\simeq g'.$ Then we have $[g']=\alpha_\#([f]).$
Now, Brown writes

Also, if $α_\#([f]) = [g],$ then any representative of $α$ extends to a homotopy $f\simeq g.$

I don't see why this should be obvious. I know that if $F:u\simeq v,\ F\in\alpha,$ then there is an extension of $f\cup F$ to a homotopy $G:f\simeq g'$ for some $g:X\to Y,\ g'i=v.$ And this $g'$ is homotopic under $i$ to $g.$ But I don't see how these homotopies can be combined to a homotopy $f\simeq g$ which extends $F.$

REPLY [4 votes]: I have finally figured it out. The solution is to look carefully at the proof of Lemma 1 and  its implications.

Assume that $b\in B(u,v)$. Let $x$ be an object in $p^{-1}[u]$, that is $px=u$. As $p$ is a fibration, there is an arrow $e$, starting at $x$ and ending at an object which we will denote $y$, such that $pe=b$. Then we can define $b_\#(\bar x)=\bar y$. Of course, we have to check this is well-defined. To this end, let $x'$ be another object in $\bar x$, and let $e'$ be an arrow in $E(x',y')$ with $pe'=b$. Then there is a morphism $d:x\to x'$ such that $pd=1_u$. Now, $e'de^{-1}$ is an arrow from $y$ to $y'$ and $p(e'de^{-1})=b1_yb^{-1}=1_v$. That means that $y$ and $y'$ are in the same component of $p^{-1}[v]$. So the action of $B$ on $\pi_0p^{-1}[u]$ is well-defined. $\square$
Additionally, if $b_\#(\bar x)=\bar y$, then there is an arrow $e$, starting at $x$ and ending at some $y'$ such that $pe=b$ and $\bar y'=\bar y$. But then there is also an arrow $d:y'\to y$ with $pd=1_v$. The composition $de$ maps to $b$. So we can say that $b_\#(\bar x)=\bar y$ if and only if some arrow from $x$ to $y$ lifts $b$.

Now, if $i:A↪X$ is a cofibration and $u:A→Y$ a map, then $p:=i^*:πY^X→πY^A$ is a fibration. Further, $πY^A$ operates on the family of sets $π_0 p^{-1}[u],\ u:A\to Y$ via $α_\#\bar x=\bar y$.
To answer the question, assume that $α_\#\bar f=\bar g$ and that $H:u≃v$ is an element in $α$. Then there is an arrow $β∈πY^X(f,g)$ which maps to $α$ via $p$. If $K:f≃g$ is a representative of $\beta$, then $pβ=α$ means that $K(i×1)$ is homotopic rel $u,v$ to $H.$ The lemma 4 in my question then asserts that $K$ is homotopic rel $f,g$ to a homotopy $K':f≃g$ which extends $H$. This shows that  if $α_\#\bar f=\bar g$, any representative $H$ of $α$ can be extended to a homotopy $f≃g$.  
In particular, we can take $α=1_u$ represented by the homotopy $H$ of lenght $r$
such that $H(a,s)=u(s)$. Then $α_\#(\bar f)=\bar g$ iff $f$ and $g$ are in the same component of $p^{-1}[u]$. By the above result the constant homotopy $H:u≃u$ can be extended to a homotopy $K:f≃g$, which means that $f$ and $g$ are homotopic under $A$ and thus they are in the same homotopy class of $[(X,i),(Y,u)]$. That's why we have a bijection $$π_0p^{−1}[u]≅[(X,i),(Y,u)]$$ and, consequently, $πY^A$ acts on the set of homotopy classes:
$$α_\#:[(X,i),(Y,u)]\to[(X,i),(Y,v)]$$