ZF Axiom Schema of Replacement: Partial/Total Function?

Question: [See context below] In the formulation of the Axiom Schema of Replacement, does it matter whether we require the formula $\phi$ to represent a partial function or a total function? Is my argument below correct?

Here I asked whether, in the formulation of the Axiom Schema of Replacement, the antecedent $$\forall A\,\forall B\,\forall C:\phi(A,B)\wedge\phi(A,C)\to B=C\tag{1}$$ could be replaced by $$\forall A\,\forall B\,\forall C\,\forall D:B\in A\wedge\phi(B,C)\wedge\phi(B,D)\to C=D$$ That is, I wanted to know whether requiring the formula $\phi$ to be functional on a set or on the class of all sets mattered. As I understood, it turns out that no, since if $\phi$ is functional on the class of all sets then it is functional on all given sets and conversely, if $\phi$ is functional on a given set, we can extend $\phi$ to be functional on all sets using the Empty Set Axiom.

Now, in some places, the antecedent looks more strict in the sense that $\phi$ is required to be a total (intuitive) function instead of just a partial function. That is, the antecedent is given as $$\forall A\,\exists!B:\phi(A,B)\tag{2}$$ So, I guess that it doesn't matter whether $\phi$ is required to be a partial function or a total function.

I think it's clear that the formulation with $(1)$ says everything that $(2)$ says about a universe of sets since a total function is, in particular, a partial function.

However, why does the formulation with $(2)$ include everything that $(1)$ says? I thought that metamathematically, in our intuitive universe of sets, there must be a set $E$ being the domain of the partial function in $(1)$ and that taking $A$, in $(2)$, to be that set $E$, should assert the existence of the same set...

Clearly, $$\tag1\forall A\,\forall B\,\forall C:\phi(A,B)\wedge\phi(A,C)\to B=C$$ implies $$\tag{1'}\forall X\,\forall A\,\forall B\,\forall C:A\in X\land \phi(A,B)\wedge\phi(A,C)\to B=C.$$ On the other hand $(1')$ with $X:=\{A\}$ (that is, in the presence of Pair) implies $$\forall A\,\forall B\,\forall C:A\in \{A\}\land \phi(A,B)\wedge\phi(A,C)\to B=C$$ and hence $(1)$. Thus $(1)$ and $(1')$ are equivalent (given Pair). However, the situation with $(2)$ is (slightly) different. If you formulate Repl using $(2)$, you cannot produce the empty set from a nonempty sets with it. Particularly, you cannot reduce comprehension to replacement: Ext, Pair, Pow, Inf, and the Repl axiom scheme in the "$(2)$ variant" cannot even show the existence of $\emptyset$.
If you do have the existence of $\emptyset$, however, then Repl with $(2)$ implies Repl with $(1)$: If $\phi(X)$ is not defined for any $X\in A$, then $\{\,\phi(X)\mid X\in A\,\}$ is just $\emptyset$ and already known to exist. If on the other hand there exists $X_0\in A$ for which $\phi(X_0)$ is defined, we can augment $\phi$ to map anything where it used to be undefined to $\phi(X_0)$, i.e., $$\Phi(A,B)\equiv \phi(A,B)\lor(\phi(X_0,B)\land \neg\exists Y :\phi(A,Y))$$ Then $\{\,\Phi(X)\mid X\in A\,\}$ with function $\Phi$ is the set we expected from $\{\,\phi(X)\mid X\in A\,\}$ with the partial function $\phi$.