The opinion of the court was delivered hy
On July 1, 1897, the United States entered into a contract with one E. B. Rundle to construct buildings at the army post near Spokane, and in said contract it was provided, among other things, that payments upon the same were to be made from time to -time as the work progressed, and that from all payments twenty per cent, was to be retained until the completion of the work and the acceptance of the samé by the government. At the time of making this contract, Rundle, as principal, and respondents herein, as sureties, subsequently to the ex*3ecution of the contract, executed a bond for the faithful performance of the contract by Bundle. In consideration of the advancement of money by the appellant to enable Rundle to comply with such contract, Bundle executed and delivered to appellant a written assignment of the money due or to become due from the United States for the construction of the said buildings, and authorized and empowered it to collect, receive, and receipt for said moneys. The assistant quartermaster of the United States in charge of the. construction of said work was at once notified of this assignment, and consented thereto. Belying upon this assignment, appellant advanced to Bundle something over $41,000, only about $24,000 of which has been paid. The money advanced went to pay for material and labor which were used in the construction of the building. On the 13th day of August, 1898, there was in the hands of the United States $6,186.40, which had been earned by Bundle and which was held back by the government under the terms of the contract. At said date, Bundle failing to comply with the conditions of said contract, the respondents, as sureties, took up the work where Bundle left off and completed the same, having, before they commenced work, been notified by the appellant of the assignment to it of the twenty per cent, held back by the government. They thereafter, however, received the same from the United States and refused to pay it over to the appellant upon demand. Action was brought against the respondent by this appellant, on February 23, 1899, for skid sum of money, and the matters and things before enumerated constituted the important part of the complaint. Respondents answered and as a separate defense alleged the fact to be that they were sureties on the bond of Bundle and that, when he made his default, they, as sureties, took the contract off *4his hands and completed the same, and that the United States promised to pay to them the twenty per cent, held back. To this further answer a demurrer was interposed, on the ground that the same did not state facts sufficient to constitute a cause of defense to plaintiff’s action, which demurrer was overruled and exceptions taken. Appellant refusing to plead further, judgment for costs was entered against it, from which judgment this appeal is taken.
This ease involves the determination of the question whether or not, at the time of making this assignment, Bundle had such an interest in the fund to be so held back by the government that he could assign the same to the appellant and vest the appellant with the title to said fund; and whether an action would lie against the respondents by the appellant for the recovery of such money. We think these questions must be answered in the affirmative. There are some cases, the most of which are early ones, holding that where two claimants for the same service apply for payment to the party bound to pay, and one of them is recognized as having a just, claim and is paid to the exclusion of the other, who was in fact the one entitled, the party thus excluded derives no title, against the party receiving payment, to the money paid, and that there is no such privity between the parties as will enable the party entitled to the money to maintain an action for the same against the party receiving it. This doctrine was announced in Patrick v. Metcalf, 37 N. Y. 332, and was for a time followed by the courts of JSTew York and some few other states, though in that case we think there was a futile effort made to distinguish the case of Bradley v. Root, 5 Paige, 632. There the holder of -the mail contract from the postoffice department assigned it to the complainant, who took upon himself the *5duty of carrying the mail according to the contract, during its continuance, and was to receive therefor all the moneys which should become payable under the contract, according to the terms thereof. No notice of this assignment was given to the postmaster general. Afterwards the assignor, who was insolvent, gave the defendant an order upon the postmaster general for the moneys which might become payable on the contract, to indemnify him against a responsibility which he had incurred as indorser for the assignor. The defendant took the order, having notice of the assignment. After the moneys had been earned by the complainant under the contract, the defendant presented his order to the postmaster general and received thereon $430. It was held by the chancellor that he was equitably hound to pay it over to the complainant. The latter New York cases, however, have been inclined to abandon the doctrine of Patrick v. Metcalf, supra, and go hack to the rule announced in Bradley v. Root, supra. In Roberts v. Ely, 113 N. Y. 128 (20 N. E. 606), the court, in commenting upon this question, said:
“Assuming that the plaintiff is right in his construction of the facts, the case falls within the familiar doctrine that money in the hands of one person, to which another is equitably entitled, may he recovered in a common-law action by the equitable owner upon an implied promise arising from the duty of the person in possession to account for and pay over the same to the person beneficially entitled. The action for money had and received to the use of another is the form in which courts of common law enforce the equitable obligation. The scope of this remedy has been gradually extended to embrace many cases which were originally cognizable only in courts of equity. Whenever one person has in his possession money which he cannot conscientiously retain from another, the latter may recover it in this form of action, subject to *6the restriction that the mode of trial and the relief which can be given in a legal action are adapted to the exigencies of the particular case, and that the transaction is capable of adjustment by that procedure, without prejudice to the interests of third persons. Ho privity of contract between the parties is required, except that which results from the circumstances. The right on the one side, and the correlative duty on the other, create the necessary privity and justify the implication of a promise by the defendant to do that which justice and equity require.”
See, also, Hathaway v. Town of Cincinnatus, 62 N. Y. 434, and In re Le Blanc, 14 Hun, 8.
In Moore v. Shields, 121 Ind. 261 (23 N. E. 89), it was held that, in an action for money had and received, there need be proved no privity of contract other than such as arises out of the fact that the defendant has received the plaintiff’s money under circumstances which make it against conscience that he should retain it. In Allen v. Stenger, 14 Ill. 119, it was said:
“Assumpsit always lies to recover money due on simple contract. And this kind of equitable action to recover back money which ought not in justice to be kept is very beneficial, and, therefore, much encouraged. It lies only for money which, ea; equo et bono, the defendant ought to refund. When, therefore, according to this rule, one person obtains the money of another, which it is inequitable or unjust for him to retain, the person entitled to it may maintain an action for money had and received for its recovery. And it is not necessary that there should be an express promise, as-the law implies a promise. The scope of the action has been enlarged until it embraces a great variety of cases, the usual test being, does the money, in justice, belong to the plaintiff, and has the defendant received the money, and should he in justice and right return it to plaintiff ? These facts create a privity, and the law implies the promise to pay.”
*7•This doctrine is sustained by Wilson v. Turner, 164 111. 398 (45 E. E. 820) ; Belden v. Perkins, 78 111. 449; Farmers’ National Bank v. Bobinson (Kan.), 53 Pac. 762, and a multitude of other cases.
Outside of other authority, however, the question has been decided by this court in Soderberg v. King County, 15 Wash. 194 (45 Pac. 785, 33 L. R. A. 670, 55 Am. St. Rep. 878), where it was held that assumpsit would lie against the county for the recovery of sums charged by the sheriff as commissions upon foreclosure sales and by him mistakenly paid into the treasury, when such sums constitute a surplus in his hands to which the judgment debtor is entitled. In that case wé cited:
Pimental v. San Francisco, 21 Cal. 352; Bank of Metropolis v. First National Bank, 19 Fed. 301; Bayne v. United States, 93 U. S. 642; State v. Village of St. Johnsbury, 59 Vt. 332 (10 Atl. 531); Attorney General v. Perry, 2 Comyns, 481; Haebler v. Myers, 132 N. Y. 363 (30 N. E. 963, 15 L. R. A. 588, 28 Am. St. Rep. 589); United States v. State Bank, 96 U. S. 30; Criswell v. Whitney, 13 Ind. App. 67 (41 N. E. 78); Board of Education v. Robinson, 7 N. M. 231 (34 Pac. 295); Brand v. Williams, 29 Minn. 238 (13 N. W. 42); Knapp v. Hobbs, 50 N. H. 476.
We think there can be no question but that the assignment in this case is supported by almost universal authority. See East Lewisburg Lumber & Mfg. Co. v. Marsh, 91 Pa. St. 96; Hawley v. Bristol, 39 Conn. 26.
Again, it must not be forgotten that the respondents Avere sureties of Eundle, the defaulting contractor. It will not be claimed that Eundle would have had a defense to this action if he had succeeded in obtaining the money from the United States after having made an as*8signment of the funds to the bank. We think the sureties stand in no better position than the principal. It was doubtless upon the strength of the bond .furnished that the bank advanced the money to Bundle for the purpose of carrying out his contract, and when the sureties took up the work that Bundle had abandoned and carried it forward 'to completion, they simply placed themselves in the position which Bundle had occupied, aided in this endeavor by the money which Bundle had obtained from the bank and which had been expended in performing the contract.
We think the court erred in overruling the demurrer to the respondent’s defense, and the judgment will therefore be reversed, and the cause remanded with instruction to sustain said demurrer.
Anders, Fulleeton and Beavis, JJ., concur.