I have an open and connected set $V$ that is also simply connected. Let $a_1, \ldots, a_n \in V$ and set $U = V \setminus \{a_1, \ldots, a_n\}$. Let $B_{R_i}(a_i)$ be disjoint balls around each $a_i$ so that $\overline{B_{R_i}(a_i)} \subset U$. Let $\gamma_i$ be the circular counterclockwise path along the boundary of each $B_{R_i}(a_i)$ going around once.
Let $f: U \rightarrow \mathbb{C}\setminus \{0\}$ be holomorphic. Suppose that $n(f\circ \gamma_i; 0) = 0$ where $n(f\circ \gamma_i;0)$ is the winding number of $f\circ \gamma_i$ around $0$. I want to show that $f$ has a logarithm on $U$, i.e. there exists $g: U \rightarrow \mathbb{C}$ holomorphic so that $f = e^g$ on $U$.
I know that $n(f\circ \gamma_i; 0) = \frac{1}{2\pi i} \int_{\gamma_i} \frac{f'}{f}\ dz$, and I've also proven more generally that if $f: U \rightarrow \mathbb{C} \setminus \{0\}$ is holomorphic on an open and connected set $U$ and $\int_{\gamma} \frac{f'}{f}\ dz = 2\pi i n(f\circ \gamma; 0) = 0$ for all piecewise $C^1$ loops $\gamma$ in $U$, then $f$ has a logarithm on $U$.
I'm having trouble figuring out how to use $n(f\circ \gamma_i; 0) =0$ to show that $n(f\circ \gamma; 0) = 0$ for any piecewise $C^1$ loop in $U = V \setminus \{a_1, \ldots, a_n\}$. I feel that $V$ being simply connected will be important so that we can relate $\gamma$ to the $\gamma_i$ by homotopy. I also do not have access to the argument principle for this problem. Any hints would be appreciated.