Set $\,g(z)=z\,f'(z)$. Clearly,
$$
|g(z)|=|z\,f'(z)|\le 1,
$$
and hence $g$ is bounded in the punctured unit disc $\mathbb D\setminus\{0\}$, and hence, $g$ has removable singularity at $z=0$, and consequently, $g$ extends analytically in the unit disc.
Expand $g$ in the unit disc as $g(z)=\sum_{n=0}^\infty a_nz^n$. Then
$$
f'(z)=\frac{a_0}{z}+\sum_{n=0}^\infty a_{n+1}z^n.
$$
Let $\gamma\subset\mathbb D\setminus\{0\}$ be a closed curve. Then
$$
0=\int_{\gamma}\big(z\,f(z)\big)'\,dz=\int_{\partial B_r}\big(\,f(z)+z\,f'(z)\big)\,dz=\int_{\partial B_r}\big(\,f(z)+g(z)\big)\,dz=\int_{\partial B_r}f(z)\,dz.
$$
Hence, there exist an analytic function $F$ in $D\setminus\{0\}$, such that $F'=f$. Such an $F$ has a Laurent expansion of the form
$$
F(z)=\sum_{k\in \mathbb Z}b_kz^k
$$
and hence
$$
f'(z)=F''(z)=\sum_{k\in \mathbb Z}k(k-1)b_kz^{k-2}.
$$
This implies that the coefficient of $z^{-1}$ is the expansion of $f'$ is $0$ and hence $a_0=0$, and thus $f$ is analytic in the disc.