I'm not exactly sure if my line of reasoning is correct, and I hope to get some hints on this.
Let $X,Y,Z$ be Riemann surfaces and let $f:X\rightarrow Y$, $ g:X\rightarrow Z$ and $h:Z\rightarrow Y$ be holomorphic maps with $f=h\circ g$. If $f$ is a covering, show that $g$ and $h$ are coverings.
My proof goes as follows: Take $z\in Z$, then there exist a connected open neighbourhood $U$ of $h(z)$ such that if $W\subset X$ is a connected component of $f^{-1}(U)$, then $W\simeq U$. Let $U'$ be the component of $h^{-1}(U)$ containing $z$. I want to show the following:
(1) $U'$ is the open connected neighbourhood of $z$ that makes $g$ into a covering.
(2) $h(U')\subset Y$ is the open connected neighbourhood of $h(z)$ that makes $h$ into a covering.
For (1), If $W'$ is a component of $g^{-1}(U')$, then there exist $W'$ a component of $f^{-1}(U)$ such that $W\subset W'$. Then the restriction of $f^{-1}|_{U}$ to $f^{-1}|_{h(U')}$ gives a biholomorphic map $ h(U')\rightarrow W$.
For (2), Since $h$ is holomorphic, $h$ is an open map and so $h(U')$ is open. Since $f$ is surjective so is $h$. Thus for $y\in Y$, we can find $z\in Z$ so that $h(z)=y$. Keeping the same notation as in above, if $V$ is another component of $h^{-1}(h(U'))$, there exist $z'\in V$ possibly not equal $z$ such that $h(z')=y$. Since $g$ is a covering, $V\simeq W_0$ where $W_0$ is a component of $g^{-1}(V)$ and $W_0\subset W'_0$ where $W'_0$ is a component of $f^{-1}(U)$. By restricting $f^{-1}$, we get a composition of biholomorphic maps $h(U')\simeq W_0\simeq V$, so $h(U')\simeq V$.