By the Court,
Beatty, C. J.:This is an action by a former sheriff of Esmeralda county to recover his fees and keeper’s charges for attaching and keeping the property of the Columbus Mill and Mining Company in a suit brought by these defendants. The plaintiff had judgment in the district court and the defendants have appealed from the judgment and the order of the court overruling their motion for a new trial.
*150It will not be necessary to notice more than two of the points made in support of the appeal.
I. The defendants allege in their answer that plaintiffs services in the attachment case were rendered in pursuance of an express agreement that he was to receive nothing therefor except in case, and to the extent, that there should be a recovery in the action; and they allege that nothing was recovered by reason of the fact that the Columbus Mill and Mining Company was adjudicated bankrupt within less than four months after the issuance of the attachment.
On the trial it was admitted that the attachment in question was issued May 12, 1874, and levied May 14th; that on July 16th following, the Columbus Mill and Mining Company was adjudicated bankrupt; that a receiver was appointed and qualified, and that due notice of the proceedings in bankruptcy was filed in the court where the attachment was pending on July 21st. It was also shown by uncontradicted testimony that the property attached was finally turned over to the receiver in bankruptcy. As to whether the sheriff made the alleged agreement for a contingent compensation the evidence was conflicting.
No question was made in the district court as to the validity of such a contract, but the case was tried and the issue submitted to the jury upon the theory that the alleged agreement, if proved, was binding on the plaintiff. In this court counsel for respondent have suggested in argument that an agreement by a sheriff, that the payment of his fees for serving process should be contingent upon the success of the plaintiff, would be contrary to good morals and public policy, and therefore void. The point, however, has not been presented or argued in a manner to justify us in deciding it at this time. It is sufficient for the present purpose to say that, admitting the correctness of respondent’s proposition, it would not affect our conclusion, that the judgment of the district court must be reversed. For under the instruction to the jury, which we are about to notice, their verdict must have been in favor of the plaintiff, notwithstanding they were satisfied his services were rendered *151in pursuance of this supposed illegal and fraudulent contract; whereas the law is settled, so far as this court is concerned, that such a contract can never be enforced. (McCausland v. Ralston, 12 Nev. 195.)
We propose, however, to examine the rulings of the district judge in the light of the theory upon which the case was tried, and, assuming that the alleged agreement, if made, was not illegal, to determine whether the following instruction was erroneous: “If you believe that the plaintiff agreed to receive his pay for services rendered only in the event that defendants (plaintiffs in the action, McLeod et al. v. Columbus M. and M. Co.) recovered from defendant in said action, and plaintiffs gave him nothing, nor promised him nothing for so agreeing, then you will find for the plaintiff.”
This instruction, to the giving of which the defendants excepted, is awkwardly expressed, but its meaning is apparent except as to the words' “ services rendered,” which, in the light of the testimony, must have been understood in the sense of services to be rendered. So construed, the instruction was erroneous. The right of a sheriff to be paid for his services is of no higher or more sacred character than that of a private person. If either is unconditionally requested to perform a service for another, the law implies a promise to pay, in one case the reasonable value, in the other the legally ascertained value, of the service. If the service is performed, the employer is bound to pay because, and only because, he has promised to pay. But if, for the sake of obtaining an employment, a private person expressly stipulates for a contingent reward, it can not be doubted that he is bound by his agreement; the obtaining of the employment is all the consideration necessary to support it, and there is no reason (aside from the question of morality above alluded to) why a sheriff may not bind himself by a similar stipulation. In such case, when he comes to demand payment, the question will be, not whether he was paid or promised anything for agreeing to serve for a contingent reward, but whether the condition upon which the employer agreed to be bound, has been fulfilled; if it has *152not, no payment' is clue. The position of a sheriff under such contract maybe worse, but can not be better than that of a private person. He must recover, if at all, under the contract; if the contract is in violation of his official duty, it is void.
II. Nearly one thousand dollars of the amount recovered by the plaintiff in the district court was on accountof keeper’s, charges for keeping the property attached after the Columbus Milling and Mining Company had been adjudicated bankrupt. Appellants contend that the receiver of the estate was alone liable for those charges.
The facts in relation to this branch of the case are that the receiver, immediately upon his appointment, notified the keeper of the property and requested him to keep it for him. The keeper made no response to this proposition, and, it seems, failed to inform the sheriff. The result was that the property remained in his charge for nearly a year after the attachment had been dissolved before there was any order of court to turn it over to the receiver. Upon this state of the case the district judge instructed the jury in effect that the sheriff, being compelled to hold the property in obedience to the writ of attachment until relieved by order of that court, was entitled to recover his charges from the attaching creditors.
This was error. The adjudication of bankruptcy dissolved the attachment and vested the title to the property in the assignee. (R. S. sec. 5044). It may have been the duty of the sheriff to hold the property till ordered by the court to turn it over (Johnson v. Bishop, 8 N. B. R. 533), but from the date of the dissolution of the attachment he, or his keeper, became divested of all official relation thereto and became a simple bailee thereof to the use of the assignee, who thereupon became liable for the cost of preserving it. (In re Preston, 6 N. B. R. 545; Gardner v. Cook, 7 Id. 346; Zeiber v. Hill, 8 Id. 239; In re Fortune, 2 Id. 662). The attaching creditors, if liable at all under their contract with the sheriff, were liable only for the costs accruing before the dissolution of the attachment. If this rule ever works a hardship upon the officer who has levied an attachment, *153such cases must be of very infrequent occurrence, for ordinarily be is fully protected by the liability of the assignee; and any other rule would almost invariably be productive of much greater hardship to the attaching creditor. But whatever may be the operation of the rule in general, in this case it is vindicated by the result. If the sheriff did not have actual knowledge of the bankruptcy of the Columbus Milling and Mining Company he is at least chargeable with the actual knowledge of the keeper, who was his chosen agent, and if he was going to hold the attaching creditors for the costs of keeping the property, on the plea that he Avas bound to keep it until relieved by an order of court, then it Avas his duty to inform them of the demand of the receiver so that they might save themselves further useless expense by releasing the attachment. He excuses himself for not informing them upon the ground that the keeper did not inform him; but, as above stated, the fault of his chosen agent is imputable to him, and besides it does not appear that he has- ever paid the keeper. In every vieAv the merits of the case, so far as this point is concerned, appear to be on the side of the appellants.
The judgment and order appealed from are reversed and the cause remanded for a netv trial.