
    EFCO CORPORATION, Plaintiff-Appellant, v. U.W. MARX, INC., Defendant-Cross-Defendant-Cross-Claimant-Appellee, Patriot Door & Window, Inc., Defendant-Cross-Defendant-Appellee, Joseph Francese, Inc., Counter-Claimant-Cross-Claimant-Cross-Defendant-Appellee.
    No. 1652, Docket 96-9473.
    United States Court of Appeals, Second Circuit.
    Argued May 22, 1997.
    Decided Sept. 3, 1997.
    
      Allan C. Samuels and Kenneth D. Green-wald, New York City, for Appellant EFCO Corporation.
    Suzanne H. Charles, Clifton Park, NY, for Appellee U.W. Marx Inc.
    Chris S. Dodig, Donovan & O’Connor, Adams, MA, for Appellee Joseph Franeese, Inc.
    Before: WALKER, McLAUGHLIN, PARKER, Circuit Judges.
   McLAUGHLIN, Circuit Judge:

BACKGROUND

In July 1991, Joseph Franeese, Inc. (“Franeese”) became the general contractor of a construction project at an elementary school in Troy, New York. Franeese subcontracted with Patriot Door & Window, Inc. (“Patriot”) to put in windows at the school. Around the same time, U.W. Marx (“Marx”) was the general contractor for a similar construction project at an elementary school in New Paltz, New York. Marx also subcontracted with Patriot to put in windows at the New Paltz site.

In June 1991, EFCO Corporation contracted with Patriot to supply the necessary windows to Patriot to use on both projects. Because Patriot was installing windows at both sites and EFCO was supplying the windows for both, confusion arose as to who was paying for what at each project. In mid-January 1992, EFCO got a check for $90,-462.09 from Patriot; a note on the check indicated that it was in payment for EFCO’s windows on the Troy project (Franeese). The check bounced.

A few days later, EFCO’s people spoke with representatives of Patriot and Marx (New Paltz) — but, notably, not Franeese. Patriot explained that a second check was on the way, and Marx now told EFCO that the check was in payment for EFCO’s work on the New Paltz project, not the Troy project. There was no note on this check. Relying on Marx’s representations and apparently failing to compare the amount of the check with its own invoices, EFCO accepted the check as a payment on the New Paltz account (Marx).

Confusion and controversy reigned. In September 1992, EFCO entered into a full release (“the release”) with Marx, upon the understanding that Patriot owed EFCO $17,-884.71 for the work on the New Paltz project. In exchange for Marx’s payment to EFCO of the $17,884.71, the release stipulated that EFCO discharged Marx from any further liability stemming from the New Paltz project and that EFCO would not file any mechanic’s lien against the New Paltz property. Much later, Patriot claimed that Marx had been mistaken and that the $90,462.09 cheek had actually been issued for work on the Troy project, and that Patriot owed much more than $17,884.71 on the New Paltz project.

Ultimately, EFCO supplied windows and other materials worth approximately $260,-000 for both projects. Patriot paid EFCO less than half that amount, and neither Marx nor Francese paid the full amount it owed Patriot, their common subcontractor. Apparently bound by the terms of the release, EFCO filed a mechanic’s hen in August 1992, but only against the property at the Troy school (Francese), and not the New Paltz school (Marx).

In February 1993, EFCO sued Patriot, Francese and some other defendants in New York State court to foreclose on the hen in satisfaction of $194,809.32 it claimed it was owed. See EFCO Corp. v. Patriot Door & Window, Inc., No. 1634/93 (N.Y.Sup.Ct. Feb. 11, 1993). EFCO did not sue Marx.

When Francese and other defendants moved for summary judgment, EFCO cross-moved to amend its complaint to add claims of unjust enrichment and quantum meruit against Francese. The court denied the cross-motion because EFCO failed to attach the appropriate supporting affidavit. The court then granted Franeese’s motion for summary judgment on the ground that EFCO failed to file suit to foreclose the hen within the six-month limitations period set forth in section 18 of New York’s Lien Law. See N.Y. Lien Law § 18 (McKinney 1993).

Undeterred, EFCO then turned to federal court. EFCO sued Francese, Marx and Patriot in the Northern District of New York in March 1995, alleging breach of contract and unjust enrichment against Patriot, and unjust enrichment and quantum meruit against Francese and Marx. Francese moved for summary judgment, arguing that EFCO’s claims against Francese were barred by res judicata, based upon the state-court ruling. Marx also moved for summary judgment, pointing to the release and to the absence of a contract between itself and EFCO.

The district court granted both motions. EFCO appeals, arguing that (1) the state-court judgment should not be given preclu-sive effect, because it was not a decision “on the merits”; and (2) it was duped into applying payments to the wrong account and should therefore be able to maintain the current action against all the named defendants, including Marx.

DISCUSSION

We review a grant of summary judgment de novo, drawing all factual inferences and resolving all ambiguities in favor of the nonmoving party. See Torres v. Pisano, 116 F.3d 625, 630 (2d Cir.1997).

I. EFCO v. Francese: Res Judicata

We are required to give the state-court judgment the same preclusive effect it would have in New York. See 28 U.S.C. § 1738 (1994); Migra v. Warren City Sch. Dist. Bd. of Educ., 465 U.S. 75, 81, 104 S.Ct. 892, 896, 79 L.Ed.2d 56 (1984). Under New York law, a prior decision dismissed “on the merits” is binding in all subsequent litigation between the same parties on claims arising out of the same facts, even if based upon different legal theories or seeking different relief on issues which were or might have been litigated in the prior action but were not. See Burgos v. Hopkins, 14 F.3d 787, 790 (2d Cir.1994); see also Restatement (Second) of Judgments § 19 cmt. f reporter’s note (1982) (hereinafter Restatement); id. § 25 cmts. d, f and j.

We address two principal questions: (1) whether the state-court judgment was “on the merits” for purposes of res judicata; and (2) whether EFCO’s instant claims against Francese are so related to the lien-foreclosure action that they could have been brought in the state-court action.

A. On the Merits

Under New York law, an action dismissed in a New York court for failure to sue within the applicable statute of limitations is considered a determination “on the merits” for res judicata purposes. See Bray v. New York Life Ins., 851 F.2d 60, 64 (2d Cir.1988) (citing cases); Smith v. Russell Sage College, 54 N.Y.2d 185, 445 N.Y.S.2d 68, 72, 429 N.E.2d 746, 750 (1981); De Crosta v. A. Reynolds Constr. & Supply Corp., 41 N.Y.2d 1100, 396 N.Y.S.2d 357, 358-59, 364 N.E.2d 1129, 1130 (1977) (citing eases); see also Restatement, supra, § 19 cmt. a. New York courts view such a dismissal as “on the merits” because a statute of limitations is a legislative limit on a party’s ability to bring an action, see United States v. Kubrick, 444 U.S. 111, 117, 100 S.Ct. 352, 356-57, 62 L.Ed.2d 259 (1979), and a dismissal based on a statute of limitations constitutes a final resolution of the party’s remedy in that it “bars the remedy sought to be enforced and terminates the right of access to the courts for enforcement of the existing right.” Consolidated Rail v. Primary Indus. Corp., 868 F.Supp. 566, 576 (S.D.N.Y.1994); see 10 Jack B. Weinstein et al., New York Civil Practice: CPLR ¶ 5011.11, at 50-115 (1997).

On the other hand, an action dismissed on the basis of a failure to satisfy a “condition precedent” is generally not a decision on the merits: it does not preclude subsequent satisfaction of the condition and enforcement of the statutory right. See Restatement, supra, § 20(2) cmts. k and m, illus. 6; cf. Carrick v. Central Gen. Hosp., 51 N.Y.2d 242, 434 N.Y.S.2d 130, 135-37, 414 N.E.2d 632, 637-38 (1980). Hence, a party’s failure to satisfy a condition precedent does not necessarily bar his remedy. See Restatement, supra, § 20 cmt. k.

Section 10 of New York’s Lien Law provides that a prospective lienor must file a notice of lien within eight months after providing the materials that serve as the basis of the lien. See N.Y. Lien Law § 10 (McKinney 1993). Section 18 adds that “[i]f the lien is for labor done or materials furnished for a public improvement, it shall not continue for a longer period than six months from the time of filing the notice of such lien, unless an action is commenced to foreclose such lien within that time.” Id. § 18. After six months, the lien is “discharged” by “lapse of time.” Id. § 21(2)(a).

EFCO’s state suit to foreclose on the mechanic’s lien was dismissed because EFCO faded to foreclose or extend the lien within the requisite six-month period. Hoping to avoid the res judicata effect of a determination “on the merits,” EFCO argues that its failure to foreclose constituted a failure to satisfy a condition precedent, rather than a failure to sue within the applicable statute of limitations.

We should take care to examine the practical function of the limitation period. New York’s Court of Appeals has observed that for purposes of determining the res judicata effect of a prior judgment the Restatement (Second) of Judgments “completely abandoned the term ‘on the merits.”’ Russell Sage College, 445 N.Y.S.2d at 72 n. 3, 429 N.E.2d at 750 n. 3. The current Restatement explains that “judgments not passing direetly on the substance of the claim have come to operate as a bar,” and thus the use of the locution “on the merits” has “possibly misleading connotations.” Restatement, supra, § 19 cmt. a. Commentators stress that to determine the res judicata effect of a prior claim requires examination of “what was intended by the first decision and what the logical consequences of that decision are.” Weinstein, supra, ¶ 5011.11, at 50-114.

The six-month limitation period here operated as a statute of limitations. The dismissal was not based on EFCO’s failure to comply with technical criteria or matters of form or procedure that are easily corrected. See 46 Am.Jur.2d Judgments § 478 (1969); cf. Restatement, supra, § 20 cmt. k reporter’s note (citing cases). The state court’s determination that EFCO failed to bring suit within the six-month period constituted a final judgment on EFCO’s remedy. See Grebe Yacht Sales, Inc. v. The Vessel “Gapuccino”, No. 89 C 5323, 1990 WL 106527, at *2-4 (N.D.Ill. July 9, 1990) (The state court’s dismissal of plaintiffs chattellien-foreclosure action on the basis of the one-year limitations period of the Illinois Chattel Lien Act, which expires automatically, is a decision on the merits).

The case law on which EFCO relies does not compel a different conclusion. In Utica Sheet Metal Corp. v. Myers-Laine Corp., 45 A.D.2d 116, 357 N.Y.S.2d 137 (1974), the court held that plaintiffs failure to notify defendants of the filing of the lien before suing to enforce the lien within the requisite six-month period was, indeed, a failure to satisfy a condition precedent. Plaintiff could have given notice and then foreclosed the lien, and thus was not precluded on the basis of res judicata from bringing a subsequent related action. See id. 357 N.Y.S.2d at 138-40. Here, however, EFCO could not simply remedy its error and bring a second action: the six-month clock had run.

In In re T.A. Maloney Contracting Corp., 85 Misc.2d 838, 380 N.Y.S.2d 585 (App.Div. 1976), the court held that a plaintiff may have the right to file more than one lien against the same property and the failure to prosecute one lien within six months does not preclude, on the basis of res judicata, the prosecution of a second lien within the six-month period. See id. 380 N.Y.S.2d at 586. The court’s holding merely highlights that a party may file a second lien for a variety of reasons under the Lien Law: to cure an irregularity in the first lien, see Berger Mfg. Co. v. City of New York, 206 N.Y. 24, 99 N.E. 153, 155 (1912); to reassert a lien — filed within the applicable notice limitations period — when the prior one has been lost by delay in its enforcement, see id.; or to account for work done by the lienor since the first lien was filed, see Clarke v. Heylman, 80 A.D. 572, 80 N.Y.S. 794, 797 (1903). Here, EFCO failed to file a second lien, and the limitation period prevented it from doing so after the state-court dismissal.

Finally, in Plattsburgh Quarries, Inc. v. Palcon Industries, Inc., 129 AD.2d 844, 513 N.Y.S.2d 861 (1987), plaintiff in his initial suit sought to collect certain payments and interest charges it incurred in keeping its industrial plant open past normal operating hours to pave a roadway and parking facilities at a prison. The court determined that these costs were not “proper subjects of a public improvement lien.” Id. 513 N.Y.S.2d at 862. The court thus held that plaintiff’s subsequent suit was not barred by res judicata, because in the initial suit “as a matter of law, plaintiff had no lien upon which to foreclose,” and, accordingly, his initial suit had not been dismissed on the merits. Id.

Here, the basis for the dismissal of the initial suit was not that EFCO never had a valid lien upon which to foreclose, but that it failed to foreclose within the requisite time period. In contrast to Plattsburgh, here there was at one point an enforceable lien in place, and the remedy for the enforcement of the lienor’s right was barred by the passage of time.

Accordingly, EFCO’s state-law claim was dismissed “on the merits” under New York law.

B. Transactional Analysis

While New York regards a dismissal on statute-of-limitations grounds as a decision “on the merits” for res judicata purposes, that is only half the analysis. Under the transactional-analysis approach to res ju-dicata, “once a claim is brought to a final conclusion, all other claims arising out of the same transaction or series of transactions are barred, even if based upon different theories or if seeking a different remedy.” O’Brien v. City of Syracuse, 54 N.Y.2d 353, 445 N.Y.S.2d 687, 688, 429 N.E.2d 1158, 1159 (1981).

EFCO could certainly have brought its claims against Francese for quantum me-ruit and unjust enrichment in the earlier state-court action. See 53 Am.Jur.2d Mechanics’ Liens § 340 (1970); N.Y. Lien Law §§ 24, 54. A plaintiff may bring an action to foreclose a lien in connection with traditional common-law remedies. See Edward Marks, Jensen on the Mechanics’ Lien Law (and Related Procedures) of the State of New York § 356 (4th ed.1963). Compare Worlock Paving Corp. v. Camperlino, 207 AD.2d 975, 617 N.Y.S.2d 87, 88-89 (1994) (common-law causes of action and action to foreclose lien in same suit); Perma Pave Contracting Corp. v. Paerdegat Boat and Racquet Club, Inc., 156 A.D.2d 550, 549 N.Y.S.2d 57, 58-59 (1989) (same); John W. Cowper Co. v. Buffalo Hotel Dev. Venture, 120 Misc.2d 350, 466 N.Y.S.2d 568, 570-72 (S.Ct.1983) (same), reversed on other grounds, 99 AD.2d 19, 471 N.Y.S.2d 913 (1984).

It is not without significance that EFCO sought to amend its complaint in state court to assert claims of unjust enrichment and quantum meruit, but the state court denied the motion. EFCO failed to appeal that decision. Where a plaintiffs motion to amend its complaint in the first action is denied, and plaintiff fails to appeal the denial, res judicata applies to the claims sought to be added in the proposed amended complaint. See Restatement, supra, § 25 cmt. b; see, e.g., Huck v. Dawson, 106 F.3d 45, 49-50 (3d Cir.1997); Walton v. Eaton Corp., 563 F.2d 66, 71 (3d Cir.1977); Sendi v. NCR Comten, Inc., 624 F.Supp. 1205, 1206-07 (E.D.Pa.1986). In such situations, regardless of the state court’s reasons for denying leave to amend, it may fairly be said that plaintiff has failed to avail himself of an opportunity to pursue a remedy in the state-court action, and thus application of res judicata is warranted. See Restatement, supra, § 19 cmt. a; id. § 25 cmt. b; id. § 26 cmt. b.

EFCO’s lien-foreclosure action and its current claims against Francese obviously arise from the same transactions. Cf. Worlock, 617 N.Y.S.2d at 88-89; Perma Pave, 549 N.Y.S.2d at 58-59. Compare Graystone Materials Inc. v. Pyramid Champlain Co., 198 A.D.2d 740, 604 N.Y.S.2d 295, 296-97 (1993) (holding that plaintiffs action to foreclose its mechanic’s lien and its claim for unjust enrichment were related for purposes of res judicata); John W. Cowper, 466 N.Y.S.2d at 571 (holding that plaintiff’s action to foreclose its mechanic’s lien and its claim for unjust enrichment were related for purposes of determining plaintiff’s right to a jury for its claims in law and equity). Accordingly, EFCO’s current claims against Francese, which could have been raised in the initial lien-foreclosure proceeding, are barred by res judicata. See Graystone, 604 N.Y.S.2d at 296-97; see also Cornwall Warehousing, Inc. v. Town of New Windsor, — A.D.2d-, 656 N.Y.S.2d 329, 330-31 (1997) (plaintiffs who were defendants in an earlier action to foreclose a common-charge lien were barred by res judicata from suing to challenge the formation of the condominium and certain by-laws, because they could have raised these claims in the foreclosure action).

Other courts that have considered this issue have held that common-law claims that could have been brought in an earlier lien-foreclosure action are barred by res judicata in a later suit, absent an agreement to the contrary by the parties. See Bank of Tokyo Trust Co. v. Aurora Mkt. Place, Ltd., No. 92 C 1692, 1993 WL 462840, at *6-7 (N.D.Ill. Nov.8,1993); Joseph T. Ryerson & Son, Inc. v. Manulife Real Estate Co., 238 Ill.App.3d 550, 179 Ill.Dec. 631, 634-35, 606 N.E.2d 463, 466-67 (1992); Thorleif Larsen and Son, Inc. v. PPG Indus., Inc., 177 Ill.App.3d 656, 126 Ill.Dec. 738, 740-41, 532 N.E.2d 423, 425-26 (1988); Sjostrom v. McMurray, 47 Ill.App.3d 1040, 6 Ill.Dec. 109, 113, 362 N.E.2d 744, 748 (1977); cf. Goldberg v. R.J. Longo Constr. Co., 54 F.3d 243, 245-46 (5th Cir.1995) (applying transactional test of res judicata under Texas law and concluding that a lien-foreclosure action that could have been brought in an earlier proceeding involving putative’s lienor’s breach-of-contract action is barred by res judicata); Kondratowicz v. Riley, No. 105287, 1995 WL 55116, at *2-3 (Conn.Super.Ct. Feb.3, 1995) (applying transactional test of res judicata under Connecticut law and concluding that contract-based. claims and lien-foreclosure claim could have been brought in an earlier small-claims action based on same contract); Home State Bank v. P.B. Hoidale Co., 239 Kan. 165, 718 P.2d 292, 295 (1986) (holding that plaintiff could have sought both a personal judgment against defendant and foreclosure of its mechanic’s lien in a single action and concluding that plaintiff thus waived its right to foreclose its lien); P.J. Constr. Co. v. Roller, 287 S.C. 632, 340 S.E.2d 564, 566 (1986) (holding that, if a prior suit involving foreclosure of a mechanic’s lien resulted in a “final adjudication on the merits,” a subsequent suit based on breach of contract would be barred).

As we noted in Bray v. New York Life Ins., 851 F.2d 60, “there is no principled basis upon which to distinguish [plaintiff’s] case from the governing New York law____ Once a plaintiff has entered the state court system, [it] is bound by the preclusion rules governing that system, and the federal courts in turn must respect the finality of judgments that issue from the state court.” Id. at 64.

Accordingly, EFCO’s claims for unjust enrichment and quantum meruit against Fran-cese are barred by res judicata.

II. EFCO v. Marx: Unjust Enrichment and Quantum Meruit

“ ‘[A] landowner is not liable to a subcontractor for work performed on the owner’s property in furtherance of the subcontract in the absence of an agreement to pay the general contractor’s debt or circumstances giving rise to such an obligation.’” U.S. East Telecomms., Inc. v. U.S. West Communications Servs., Inc., 38 F.3d 1289, 1297 (2d Cir.1994) (quoting Schuler-Haas Elec. Corp. v. Wager Constr. Corp., 57 A.D.2d 707, 708, 395 N.Y.S.2d 272 (N.Y.App. Div.1977)). “This principle is equally applicable where ... the parties are a primary contractor and a second-tier subcontractor rather than a landowner and subcontractor.” Id.

EFCO made its contract with Patriot, not Marx. Accordingly, as á general rule, EFCO would not be entitled to recover from Marx for the related claims of unjust enrichment and quantum meruit. There are exceptions. In U.S. East we examined the circumstances under which “a general contractor may become hable in- quasi-contract to a ‘second-tier’ subcontractor with whom it has not eontraet-éd.” Id. at 1291. We explained that the courts must inquire “whether the landowner acted in such a way as to incur obligations to the subcontractor outside the contractual structure.” Id. at 1297. We defined when such an obligation could arise. We noted that the contractor may incur “quasi-contractual obligations to a third party with whom it has not contracted, by virtue of its direct representations to that party,” id., explaining that recovery in quasi-contract “may be had if a party has rendered additional services upon extra-contractual representations by the other party.” Id. at 1298. We summarized these exceptions by concluding that

under New York law, a subcontractor may recover from a landowner (and a sub-subcontractor from a general contractor), even when a separate contract exists between the subcontractor and. general contractor, if the owner has agreed to pay the general contractor’s debt or if the circumstances surrounding the parties’ dealings can be found to have given rise to an obligation to pay.

Id.

Here, EFCO has produced no satisfactory evidence that Marx encouraged EFCO to begin or continue to work on the basis that Marx would pay EFCO in the future. EFCO suggests the following evidence: (1) EFCO sent drawings of windows, test reports and wood-finish samples to Marx for approval and verification; and (2) Marx’s controller was in periodic contact with EFCO during the course of Patriot’s involvement with the New Paltz project.

These facts are hardly material. EFCO does not allege — and the evidence does not suggest — that Marx conditioned its paying EFCO on EFCO’s production of these materials. EFCO’s allegations indicate only that Marx’s controller maintained contact with EFCO precisely because Marx wished to insure that the money Marx had paid Patriot would subsequently be paid to EFCO.

The fact that Marx entered into the release is similarly immaterial. The rationale for the narrow exception delineated in U.S. East is that the subcontractor completes its work for the benefit of the contractor, not the landowner. See Sybelle Carpet and Linoleum of Southampton, Inc. v. East End Collaborative, Inc., 167 A.D.2d 535, 562 N.Y.S.2d 205, 206 (1990); Schuler-Haas, 395 N.Y.S.2d at 274. This presumption is overcome, and the landowner may be liable, where the landowner prompts the subcontractor to undertake its work or to continue its work under the assumption that the landowner will pay it directly. See U.S. East, 38 F.3d at 1298-99; Schuler-Haas, 395 N.Y.S.2d at 274; Custer Builders, Inc. v. Quaker Heritage, Inc., 41 A.D.2d 448, 344 N.Y.S.2d 606, 609 (1973); Woodruff v. Rochester & P.R. Co., 108 N.Y. 39, 14 N.E. 832, 833-34 (1888); J.R. Kemper, Annotation, “Building and Construction Contracts: Right of Subcontractor Who Has Dealt Only with Primary Contractor to Recover against Property Owner in Quasi Contract,” 62 A.L.R.3d 288, 294-95 (1975).

Here, EFCO and Marx entered into the release after EFCO had performed its work on the projects. The release does not suggest that EFCO completed the work based on its supposition, or Marx’s representation, that Marx would pay EFCO directly. The release provides no indication that “in furtherance of the subcontract” EFCO expected Marx to ignore Patriot’s obligations and pay EFCO directly. The release states that EFCO completed its work on the New Paltz project pursuant to its contract with Patriot. Patriot’s position as the operative “middleman” between Marx and EFCO was cemented, rather than disregarded.

In sum, there is no evidence that in order to have EFCO undertake or complete its work on the projects, Marx expressed a willingness to pay EFCO for the work or otherwise assumed an obligation to pay for the work. Accordingly, the district court properly granted Marx’s motion for summary judgment. See Metropolitan Elec. Mfg. Co. v. Herbert Constr. Co., 183 A.D.2d 758, 583 N.Y.S.2d 497, 498 (1992); Perma Pave Contracting Corp. v. Paerdegat Boat and Racquet Club, Inc., 156 A.D.2d 550, 549 N.Y.S.2d 57, 58-59 (1989); cf. Westinghouse Elec. Supply Co. v. R.P. Brosseau and Co., 156 A.D.2d 851, 549 N.Y.S.2d 851, 852-53 (1989).

CONCLUSION

We have considered all of EFCO’s other arguments and find them to be without merit. Accordingly, the order of the district court is affirmed.  