The defendant Micolino was the owner of property, and entered into an agreement with the defendant Wood, as contractor, under the terms of which the latter was to furnish material and do all the carpenter work on the two houses to be erected, for which Micolino was to pay in installments as the work progressed, the final payment to be made “when the buildings are completed and this contract fulfilled.” The contract further provided that if the contractor should fail to supply a sufficiency of workmen or materials, or to prosecute the work with promptness and diligence, the owner could, on notice, provide such labor and materials, and the expense of furnishing the same, and the damage resulting to the owner from the contractor’s failure, should be deducted from any moneys that might become due the contractor under the contract. It further provided that a final payment should not be made until the contractor should give the architect satisfactory evidence that there were no liens or claims chargeable against the contractor; and, further, that, if there were any, the owner could retain from any payments a sufficient amount to indemnify him completely against the same until they should be satisfied and discharged. The contractor, Wood, entered into a subcontract with the plaintiffs, by which the latter were to furnish certain trimmings for the buildings at an agreed price, and thereafter plaintiffs commenced performance of that agreement. Subsequently Wood gave to the plaintiffs a written order upon the owner to pay to plaintiffs certain amounts as therein specified, and to charge the same to his (Wood’s) account. The testimony is that this order was delivered to Micolino, and retained by him for consideration; but whether it was accepted by him, or whether the payment made subsequent thereto was in accordance with the terms of such order, or by another arrangement between the parties, is in dispute,—one of plaintiffs’ witnesses testifying that the order was accepted, and that the payment was made under the order. However this may be, after the order was given, the contractor having failed to perform his contract, the owner, after notice, entered upon and completed the buildings, employing suitable persons to furnish the work and materials, and paying them therefor out of the moneys held by him and reserved for the final payment; and, after such payments made, there remained in Micolino’s hands the sum of $1,821.35, out of which the plaintiffs claimed the balance due them of $1,662.50. The trial judge dismissed the complaint, upon the ground that, even if it were proved that the order was delivered, plaintiffs could not recover, because “the conditions precedent stated in the contract have not been complied with.” The specific conditions were not pointed out by the judge, but we assume one to be that, as the final payment was to be made “when the balance of material is delivered, and the carpenter’s contract entirely finished,” no recovery could be had on account of the contractor’s failure fully to complete. This might have been a correct ruling, if the contract had provided for' the finishing by the original contractor; but the *1111contract itself showed that, in the event of the contractor not finishing, the owner had the right to complete the work at the expense of such contractor. In other words, upon the failure of the contractor to complete as required by the terms of the' contract, the owner, as the agent for the contractor, had the right to finish the work, and deduct the expense thereof from the final payment coming to the contractor. This was the course followed by the owner, who testified that he went on and finished the buildings under the contract, and, after finishing and making the payments, there remained in his hands the sum already mentioned.
As the complaint was drawn, it would seem that the theory of plaintiffs’ action was to charge the defendant Micolino personally with the obligation of the payments under the order, upon the ground that he had accepted the same; and if the motion to dismiss had been predicated upon defective pleadings, there might be a basis for the ruling made dismissing the complaint. The court, however, expressly stated that its ruling was not upon any defect in pleading, but was on account of defect of proof; and therefore, as the complaint might have been amended if such objection had been made, we have a right to consider the proof for the purpose of determining whether the plaintiffs were entitled to any relief. There was some evidence, though slight, upon the question of acceptance. But apart from this, upon the question of delivery of the order, there was sufficient evidence for it to go to the jury as a question of fact, and upon this appeal we must assume that it might have been resolved in plaintiffs’ favor. Assuming, therefore, that the order was delivered, though not accepted, its effect has been determined in two cases, which seem to us to dispose of the questions presented. Lauer v. Dunn, 115 N. Y. 405, 22 N. E. 270; Beardsley v. Cook, 143 N. Y. 143, 38 N. E. 109. In Lauer v. Dunn, which, like this, was a controversy over payments under a building contract, it was provided that the final payment should be made “within thirty days after its final completion and acceptance by the architect.” It was also provided that, in case any liens should exist upon the property at the time any payment was to be made, such payment, or such part thereof as shall be equal to not less than double the amount of such liens, should not be payable at the stipulated times. Upon the completion of the buildings, there was due the contractor $750, against which an order was drawn directing payment to subcontractors of $700, with a request that it be charged to the contract. The subcontractors presented the order, but it was not paid. A few days after liens were filed by various parties. In an action brought by plaintiffs upon the order, commenced more than 30 days after the completion of the buildings, plaintiffs were nonsuited. “Held error; that the order amounted in law to an assignment, pro tanto, of the fund in the owner’s hands; that it having been made in good faith, and for a valuable consideration, and notice thereof given to the owner prior to the filing of any lien, no subsequent liens could defeat plaintiffs’ right to the money, and the owner would have been protected in its payment; that the provision respecting the owner’s right to retain double the amount of any lien filed, simply meant that if, *1112when moneys were payable to the contractor, liens existed, the owner might reserve double the amount claimed under theta for such moneys, and, as no liens existed, plaintiffs were entitled to recover.” And in Beardsley v. Cook, supra, it is said:
“The acceptance of the order by the defendant operated as an equitable assignment of so much of the last payment to the plaintiff, and the plaintiff’s right could not be affected by payments made by the defendant in advance of the work, or by the liens of mechanics or material men filed subsequent to the assignment.”
The opinion continues:
“But, unless that payment became due and payable by the defendant, the plaintiff could not, under the circumstances disclosed by the record, recover upon the order as an absolute and unconditional promise. The plaintiff’s right toi recover the payment, or that part of it assigned to him by the order, was contingent upon performance of the contract, so as to render the last installment, or at least some part of it, due and payable. The contract was not performed by the builders, but by the defendant himself, who was obliged to complete the houses. The assignment to the plaintiff was subject to any deduction which the defendant had a right to make from the payment on account of the reasonable and fair expense to him in completing the houses. He could claim payment of the order only from the balance.”
' Upon the proof as it stood, therefore, at the close of plaintiffs' case, it appeared that they had a good claim against the contractor; that there remained in the owner’s hands an amount available for the payment of plaintiffs’ claim, in whole or in part; and that the contractor had assigned his interest in such amount to an extent sufficient to provide for the payment, in whole or in part, of such claim. The election of the owner to complete the contract, instead of insisting upon the performance by the contractor, modified the relation of the parties by constituting the owner the agent of the contractor, and creating a new fund upon which the plaintiffs’ claim, fortified by the order of the contractor, attached; that is, instead of the balance under the terms of the contract, another fund was substituted, namely, so much of the contract price as remained, unpaid in the owner’s hands after deducting what he had expended to complete, which, as shown by the testimony, was $1,821.35. If there were persons other than the plaintiffs entitled to any portion of the fund, that was a matter of defense. Here was a fund which had been substituted for the balance or final payment under the original contract, and, if in respect thereto there was a dispute, the owner had it in his power to bring in all those who had any interest in the fund, or he could assume, as he did, the responsibility of contesting on their behalf the right of the plaintiffs to any portion of it; and in this connection could have shown, had he been put to his defense, just what the situation of the fund and the legal claims against it were. As the evidence stood, however, at the close of plaintiffs’ case (assuming that the pleadings would have been amended to conform to the proof), sufficient had been shown to entitle the plaintiffs, to a payment, in whole or in part, of their claim. Under such circumstances, the "dismissal of the complaint was error, for which.the judgment should be reversed and a new trial ordered, with costs to appellants to abide the event. All. concur.