Gittin, Chapter 3, Mishnah 5. This mishnah deals with an agent who is bringing a get and is unable to complete his mission, and with the question of when he may appoint another agent in his place.
The text of the mishnah:
"HaMevi get b'Eretz Yisrael v'chalah - harei zeh mishalcho b'yad acher" - an agent who undertook to bring a get within Eretz Yisrael, where there is no need to declare "it was written in my presence and signed in my presence," and who fell ill and is unable to continue his journey to deliver the get, may send the get with another agent.
"V'im amar lo: tol li heimenah chefetz peloni - lo yishlachenu b'yad acher, she'ein retzono sheyipaked mamono b'yad acher" - the husband instructed the agent that along with the delivery of the get he should take a certain object from the wife, and in such a case he may not transfer the mission to another person.
The reason for the ruling in the first part of the mishnah: as long as the agent is healthy, we are concerned that the husband may not be comfortable with the get being delivered by someone else. But once the agent falls ill, we may assume that under these circumstances the husband does not object, since he wants the mission carried out, and now that the agent has fallen ill it is understood that he must appoint another in his place.
In the second part, however: although with regard to the get itself the husband has an interest in the mission being completed, especially once the agent has fallen ill, once part of the mission involves retrieving a particular object, it is possible that he does not want his deposit - his own item that is being held by his divorcee - to pass into the hands of another person. The husband indeed wants the divorce carried out, but he does not necessarily want the other components of the arrangement entrusted to a stranger, and therefore he may not send it with another.
The Gemara's distinction - it all depends on the order of the instructions:
The Gemara explains that this halachah has several components, and the matter depends on the order in which the husband instructed the agent to give the get and to take the object. If he placed the giving of the get before the taking of the object, he is not so particular about receiving his item; but if he placed the taking of the object before the giving of the get, it is evident that he is more particular.
He said to him: "Tein lah es haget v'achar kach tol mimenah es hachefetz" - ideally he should not send it with another. But if he did send it, the get is valid in any event, whether the second agent gave the get first or took the object first, since the order of the husband's words proves that he is not so particular.
He said to him: "Tol es hachefetz v'achar kach tein lah es haget" - here the husband is particular about the order. Therefore, if the agent gave the get first, contrary to the order he was instructed, it is not a get - and this is so even if the first agent himself did this. And all the more so when he sent the mission with another, and that person gave the get first and only afterward took the object, in which case the mission is ineffective.
He sent it with another, and the second agent acted in the proper order - he took the object first and afterward gave the get: the get is valid, since in the end the husband's wish was fulfilled. Even so, ideally the rule here is "lo kol heimenu" - the mission should not be handed over to a second agent, lest he fail to convey the instructions properly and tell him the reverse order, and this order matters to the husband, who explicitly said "take the object and afterward give her the get." But after the fact, if the second agent acted in accordance with the husband's wish, the get is valid even though he is a second agent.
In summary: an agent bringing a get within Eretz Yisrael who fell ill may transfer the mission to another, since the husband wants the mission carried out. But if the husband also charged him with taking an object from the wife, he may not send it with another, since he does not want his money entrusted to a stranger. The Gemara distinguished between a case where he placed the giving of the get before the taking of the object, where he is not particular and after the fact it is valid in any order, and a case where he placed the taking of the object before the giving of the get, where he is particular about the order and the get does not take effect if the order is changed - and in any case, if the second agent acted according to the husband's instruction, it is valid after the fact.