Exercise 0.28 in Hatcher's Algebraic Topology states
Show that if $(X_1,A)$ satisfies the homotopy extension property, then so does every pair $(X_0 \sqcup_f X_1, X_0)$ obtained by attaching $X_1$ to a space $X_0$ via a map $f: A \to X_0$.
This question strikes me as trivial, so I wanted to check whether my solution doesn't gloss over any important subtleties.
The homotopy extension property guarantees that there is a retract from $X_1 \times I$ to $X_1 \times \{0\} \cup A \times I$. This induces a retract from $(X_0 \sqcup_f X_1)\times I$ to $(X_0 \sqcup_f X_1)\times\{0\} \cup (X_0 \sqcup_f A) \times I$, since $A \times I \subset X_1 \times I$ is unaffected by the retract and hence the space $X_0 \sqcup_f A$ just 'spectates'. This retract implies the pair $(X_0 \sqcup_f X_1, X_0)$ satisfies the homotopy extension property.
Is this proof satisfactory?