In chapter 2.3, Hartshorne defines a morphism $f: X \to Y$ to be locally of finite type if there is an open affine cover $\{V_i\}$ of $Y$ and open affine covers $\{U_{ij}\}$ of $f^{-1}(V_i)$ so that $\mathscr{O}_Y(V_i) \to \mathscr{O}_X(U_{ij})$ makes $\mathscr{O}_X(U_{ij})$ a f.g. algebra over $\mathscr{O}_Y(V_i)$.
My question is, what is this homomorphism? The only way it seems to obtain this is via a restriction under the assumption that $U_{ij} \subseteq f^{-1}(V_i)$. Then, we can compose the natural $\mathscr{O}_Y(V_i) \to \mathscr{O}_X(f^{-1}(V_i))$ and the restriction $\mathscr{O}_X(f^{-1}(V_i)) \to \mathscr{O}_X(U_{ij})$. This assumption is not part of the definition, though. How would we find this map if $U_{ij} \not\subseteq f^{-1}(V_i)$? The definition of "open cover" I am familiar with only requires $f^{-1}(V_i) \subset \bigcup_{j} U_{ij}$ but the condition in hartshorne seems to assume equality.
I must be missing something. I know that open affines form a base for the topology on $X$ so $f^{-1}(V_i) = \bigcup_{j} U_{ij}$ would not be a very strange condition. Is that the condition I should assume when hartshorne says that $\{U_{ij}\}$ is an open cover of $f^{-1}(V_j)$?
Thank you!