
    KELLEY LUMBER CO. v. OTSELIC VALLEY R. CO. et al.
    (Supreme Court, Appellate Division, Third Department.
    December 30, 1909.)
    1. Trial (§ 379)—By Court—Issues—Duty to Consider Evidence Admitted Over Objection.
    The court, receiving evidence of a fact over the objection that it is not within the pleadings, may not refuse to consider the evidence in determining the case.
    [Ed. Note.—For other cases, see Trial, Cent. Dig. § 894; Dec. Dig. § 379.]
    2. Appeal and Error (§ 1153)—Disposition of Case on Appeal—Correction of Error of Law.
    "Where the court found the facts and committed an error of law, the Appellate Division may render the judgment which the .court below should have rendered.
    [Ed. Note.—For other cases, see Appeal and Error, Cent. Dig. §§ 4507, 4508, 4511; Dec. Dig. § 1153.]
    
      8. Mechanics’ Liens (§ 272)—Enforcement—Pleadings.
    Where the complaint, in an action to foreclose a mechanic’s lien, admitted that a defendant and a codefendant had liens and sought an adjudication as to priority, the answer of defendant, alleging that his lien was superior to the lien of plaintiff, and that he was entitled to payment of his lien, etc., and an answer of the codefendant, admitting the complaint, and alleging that he filed the lien as alleged in the complaint, etc., sufficiently alleged the lien of defendant and codefendant within Code Civ. Proc. § 8402, subd. 3, providing that a lienor must, by answer, set forth his lien, or he will be deemed to have waived the same, unless the lien is admitted in the complaint, as against an objection raised for the first time on the trial, and in the absence of an answer by the owner under section 521, denying the validity of the liens, the court could determine the equity of the parties as authorized by section 3403.
    [Ed. Note.—Eor other cases, see Mechanics’ Liens, Cent. Dig. §§ 514-524; Dec. Dig. § 272.]
    Sewell, X, dissenting.
    Appeal from Trial Term, Madison County.
    Action by the Kelley Lumber Company against the Otselic Valley Railroad Company and others. From the judgment, certain of the defendants appeal.
    Modified and affirmed.
    The action was brought to foreclose a mechanic’s lien upon certain rights of way owned by the railroad company. The notice of lien was filed January 14, 1907. The plaintiff stated in the complaint, after the proper allegations in reference to its lien, that the defendant Burhans & Black Company filed a mechanic’s lien against the property January 9, 1907, for $996.53, and that the defendant Eloyd Currier filed a mechanic’s lien against the property January 19, 1907, for $1,042.34. The defendant Burhans & Black Company interposed an answer putting in issue the material allegations of the complaint, other than the allegation as to the said lien filed by it as aforesaid January
    9, 1907, for $996.53, which it alleged was prior and superior to the lien of the plaintiff, which was filed January 14, 1907, and that all the lienors, including the plaintiff, were junior lienors and subordinate to the rights of the defendant, and that it is entitled to the payment of its lien and interest from the proceeds of such sale prior to the other lienors. It prayed that the relief asked for in the complaint be granted, in so far as the same does not conflict with the rights and interests of this defendant, arid that out of the proceeds of said sale there shall be paid to the defendant the sum of $996.53 before application is made of any portion of the proceeds of said sale for the payment of plaintiff’s claim herein.
    The defendant Currier admitted all the allegations of the complaint, and alleged: That he filed the lien against the .Otselic Valley Railroad Company in the office of the county clerk of Madison and Chenango counties, on the 19th day of January, 1907, for $1,042.34, as alleged in the complaint; that said lien was thereafter and within 10 days served on the Otselic Valley Railroad Company as required by statute; and that said lien was sworn to and in all things complied with the requirements of the statute.
    Upon the trial the court admitted, o.ver objection and exception, evidence tending to show the material furnished by the defendants Currier and Burhans & Black Company, the agreed price or value of the same, and the other facts required by section 9 of the lien law. The court found facts sufficient to establish the liens of these defendants, but found as a conclusion of law that neither of these defendants was entitled to any relief or judgment in this action. The reason assigned for this conclusion was that “the answer of each of the defendants Burhans & Black Company and Currier is insufficient to warrant either an enforcement thereof in the decree of foreclosure, or to warrant a judgment for the amount of their claims respectively.”
    
      Argued before SMITH, P. J., and CHESTER, KELLOGG, COCH-RANE, and SEWELL, JJ.
    Hubert C. Stratton, for appellant Otselic Valley R. Co.
    John F. Nash, for appellant Burhans & Black Co.
    Arthur W. Mawson, for appellant Floyd Currier.
    M. H. Kiley, for respondent Kelley Lumber Co.
    
      
      For other cases see same topic & § number in Dec. & Am. Digs. 1907 to date, & Rep’r Indexes
    
    
      
      For other cases see same topic & § number in Dec. & Am. Digs. 1907 to date, & Rep’r Indexes
    
   JOHN M. KELLOGG, J.

The evidence fairly sustained the judgment against the railroad company, and no error is found to-its prejudice.

It is clear that the practice pursued by the court with reference fo the defendant Burhans & Black Company and Currier was erroneous. It could not receive evidence of their liens over the objection that it was not within the pleadings, and then refuse to consider such evidence in deciding the case. This procedure is not warranted by law, and must destroy a judgment based upon it. Ewald v. Poates, 107 App. Div. 242, 94 N. Y. Supp. 1106; Robinson v. N. Y. Elevated R. R. Co., 175 N. Y. 219, 67 N. E. 431.

The court therefore erroneously found that neither the Burhans & Black Company nor Currier was entitled to relief. Upon the facts found, the Burhans & Black Company had a valid lien which was superior to the plaintiff’s lien, and the defendant Currier had a valid lien which was subsequent to the liens of Burhans & Black Company and the plaintiff, and prior to the other lienors. The judgment upon the facts found should have so provided. The court having found all of the facts in their favor, and having committed an error of law in not giving them the benefit thereof, we may order the judgment which should have been granted at the trial upon the facts found. Sayre v. State, 123 N. Y. 291, 25 N. E. 163; Bryant v. Turner, 126 App. Div. 598, 110 N. Y. Supp. 594.

It would be useless formality, however, for us to direct judgment upon the facts found if the court erred in receiving the evidence upon which such findings are based. It therefore becomes important to determine whether the trial court committed error in receiving evidence of such liens over the objection that it was inadmissible under the pleadings. Section 3402 of the Code of Civil Procedure, which was in force at the time, required that all parties other than plaintiff having liens shall be made parties defendant, and section 3403 provides that the court may adjust and determine the equities of all the parties and the order of priority of different liens and determine all the issues raised by any defense or counterclaim. The allegation in the complaint that each of said parties had filed a mechanic’s lien against the property on the date and for the amount stated, and the prayer for relief that all the rights, interests, and priority of the plaintiff and of the defendants be ascertained and determined, and the answers of the said defendants, do not leave them in the position described in subdivision 3 of section 3402 of the Code of Civil Procedure of waiving their liens. Under that. subdivision every defendant who is a lienor must set forth his lien, or he will be deemed to have waived it, “unless the lien is admitted in the complaint and not contested by another defendant.” These liens were substantially admitted in the complaint. The lienors were made‘parties, not as persons claiming liens, but as persons having liens, and the plaintiff sought an adjudication as to priority. The answer of each of said defendants, read in connection with the complaint which it referred to, was a sufficient allegation of their liens when objected to for the first time upon the trial. A defendant whose rights are substantially admitted in the complaint may safely rely upon that fact. He is not in a position to know, and it is not necessary for him to inquire, what the status of the pleadings is between the plaintiff and other defendants. The lien, being substantially admitted by the complaint, is not to be deemed controverted so as to visit upon him the penalty of subdivision 3 above, unless the defendant controverts it by serving upon him an answer under section 521 of the Code of Civil Procedure challenging his rights.

All parties appeared before the court for trial. The plaintiff having substantially admitted the existence of the defendants’ liens, asserted its own lien, and sought the determination of the court as to priority of liens. The defendant lienors were there to protect their priority of liens; the railroad company to question all the liens. If the railroad company had served upon the other defendant lienors an answer asking that their liens be declared invalid, that would have required the said lienors to set forth their lien in proper issuable form. In the absence of such answer, the defendant lienors were entitled to introduce their evidence and have their liens declared. The bringing of an action to foreclose a lien brings all the parties before the court, and if a lien is established the court is to -distribute the fund among the lienors according to their respective rights.

The judgment should therefore be modified as above, and as modified affirmed, with costs to the plaintiff against the railroad company, and with costs to the Burhans & Black Company and Currier to be paid by the respondents. All concur, except SEWELL, J., who dissents. ‘  