Extending an endomorphism from a topological sub-ring to the topological ring Let $A$ be a topological ring, let $B \subseteq A$ be a topological sub-ring, and let $f: B \to B$ be a continuous endomorphism of $B$.
Assume that (forgetting about the ring structure) $f$ can be extended to a continuous map $F: A \to A$, by some theorem from topology (with $B \subseteq A$ sets, not necessarily rings).

Is it true that the fact that $B \subseteq A$ are topological rings (the addition and multiplication are continuous) guarantees that the extended continuous map $F$ is a ring endomorphism of $A$?

I think that the answer is yes (by continuity of the addition and multiplication).
Also, is it true that there are cases in which we can dismiss the assumption that $A$ is a topological ring, and just assume that it is a ring that has some topology (not necessarily compatible with addition and multiplication),
and still get that the extended continuous map $F$ is a ring endomorphism of $A$, for example, for a complete metric space $A$, $B$ dense in $A$, and $F(a):=\lim f(b_n)$,
where $\lim b_n=a$, because 
$F(aa'):= \lim f(b_nb_n')= \lim f(b_n)f(b_n')= \lim f(b_n) \lim f(b_n')= F(a)F(a')$, and similarly for addition.
 A: If $A$ is $T_0$ and complete, and $B$ is dense, then it's true, and follows from the following more general result.

Let $X$ and $Y$ be uniform spaces, let $D\subseteq X$, and let $f\colon D\rightarrow Y$ be uniformly-continuous.  Then, if $D$ is dense in $X$, and $Y$ is $T_0$ and complete, then there is a unique uniformly-continuous extension of $f$ to $X$.

Given a continuous endomorphism $f\colon B\rightarrow B$ (necessarily uniformly-continuous), under the stated assumptions, it extends to a unique uniformly-continuous function $F\colon A\rightarrow A$.  We need only check that $F$ itself is a ring homomorphism.  So, let $x,y\in A$.  Then, by density, there are nets $\lambda \mapsto x_{\lambda}\in B$ and $\lambda \mapsto y_{\lambda}\in B$ converge to $x$ and $y$ respectively (without loss of generality we can take their indexing sets to be the same).  Then,
$$
F(x+y)=F(\lim _{\lambda}x_{\lambda}+\lim _{\lambda}y_{\lambda})=F(\lim _{\lambda}(x_{\lambda}+y_{\lambda}))=\lim _{\lambda}F(x_{\lambda}+y_{\lambda})=\lim _{\lambda}f(x_{\lambda}+y_{\lambda})=\lim _{\lambda}[f(x_{\lambda})+f(y_{\lambda})]=\lim _{\lambda}f(x_{\lambda})+\lim _{\lambda}f(y_{\lambda})=F(x)+F(y).
$$
Similarly for multiplication.
