Extendability Theorem for Intersection Numbers

Theorem
Let $X = \partial W$ be a smooth manifold which is the boundary of a smooth compact manifold $W$.

Let $Y$ be a smooth manifold, $Z$ be a closed smooth submanifold of $Y$, and $f: X \to Y$ a smooth map.

Let there exist a smooth map $g: W \to Y$ such that $g \restriction_X = f$.

Then:
 * $I \left({f, Z}\right) = 0$

where $I \left({f, Z}\right)$ is the intersection number.