I am trying to prove that the restriction functor $\mathbb{r}: {\rm Sh}(X) \to {\rm Sh}(\mathcal{B})$ is an equivalence of categories, and I came across this answer (here you can also find the full statement that I am trying to solve).
So, we have the functor $\mathbb{r}$ such that $$ \mathbb{r}:{\rm Sh}(X)(F,G) \to {\rm Sh}(\mathcal{B})(r(F),r(G)),\quad \text{where} \quad f \mapsto r(f) $$
where $f$ is a natural transformation between sheaves. Now, we wish to prove the injectivity of this functor, which means, that we want to verify that for all $f,g \in {\rm Sh}(F,G)$, $\mathbb{r}(f)= \mathbb{r}(g)$, we have that $f=g$.
My first question here comes from my lack understanding on how they consider as their hypothesis for injectivity that $f(B)=g(B)$ whenever $B \in \mathcal{B}$. Is $\mathbb{r}(f)= \mathbb{r}(g) \Leftrightarrow f(B)=g(B)$? If so why?
Then, they say the following,
Now, by the hypothesis, $$f(x) {\mid_{V_i}} = f(V_i)(x {\mid_{V_i}}) = g(V_i)(x {\mid_{V_i}}) = g(x) {\mid_{V_i}}$$ for each $i$;
Where does that first equality come from? I can't seem to figure it out.
If anyone can help me in these two question I would be the most grateful!
Any help is really appreciated.