In an action, inter alia, to recover damages for violation of the Franchise Sales Act (General Business Law § 680 et seq.) and breach of contract, the defendants appeal, as limited by their brief, from so much of a judgment of the Supreme Court, Nassau County (Bucaria, J), entered July 20, 2011, as, upon a decision of the same court dated March 9, 2011, made after a nonjury trial on the issue of liability, and upon a decision of the same court (Speziale, Ct. Atty. Ref.), dated May 26, 2011, made after a nonjury trial on the issue of damages, (a) is in favor of the plaintiff and against them in the principal sum of $98,982 on the cause of action alleging breach of contract based upon their failure to indemnify the plaintiff for legal fees incurred in defending a federal trademark infringement action, and (b) failed to make any determination with respect to their counterclaims, and the plaintiff cross-appeals, as limited by its brief, from so much of the same judgment as, upon the decision dated March 9, 2011, (a) in effect, dismissed the cause of action to recover damages for violation of the Franchise Sales Act, and (b) failed to award it damages on the causes of action alleging breach of contract based upon the defendants’ delivery of meat to the plaintiff in nonrefrigerated trucks and their lack of authority to assign a certain logo.
Ordered that the judgment is modified, on the law, by adding provisions thereto severing the defendants’ counterclaims and severing the plaintiff’s causes of action alleging breach of contract based upon the defendants’ delivery of meat to the plaintiff in nonrefrigerated trucks and their lack of authority to *658assign a certain logo; as so modified, the judgment is affirmed, without costs or disbursements, and the matter is remitted to the Supreme Court, Nassau County, for a new trial on the defendants’ counterclaims and on the issue of damages with respect to the plaintiff’s causes of action alleging breach of contract based upon the defendants’ delivery of meat to the plaintiff in nonrefrigerated trucks and their lack of authority to assign a certain logo.
After a trial on the issue of liability, in a decision dated March 9, 2011, the Supreme Court, inter alia, in effect, found that the cause of action to recover damages for the defendants’ alleged violation of the Franchise Sales Act based on the doctrine of in pari delicto should be dismissed, found the defendants liable to indemnify the plaintiff for legal fees it incurred in defending a trademark infringement action in the United States District Court for the Southern District of New York (hereinafter the trademark action), and referred the matter for a hearing on damages. The March 9, 2011, decision did not make any findings with respect to the defendants’ counterclaims. In addition, despite having found that the defendants breached the parties’ agreement by delivering meat to the plaintiff in nonrefrigerated trucks and because they lacked authority to assign a certain logo to the plaintiff at the time that the agreement was entered into, the court limited the evidence at the trial on the issue of damages to the legal fees incurred by the plaintiff in the trademark action. After the damages trial, a judgment dated July 20, 2011, was entered in the plaintiff’s favor in the principal sum of $98,982, on the cause of action alleging breach of contract based on the defendants’ failure to indemnify the plaintiff for the legal fees it incurred in the trademark action.
Contrary to the defendants’ contention, the Supreme Court properly found that they were liable for indemnification, as the legal expenses incurred by the plaintiff in connection with the trademark action filed against it by a third party fall squarely and unambiguously within the ambit of the indemnification clause of the parties’ agreement (see Breed, Abbott & Morgan v Hulko, 139 AD2d 71, 73 [1988], affd 74 NY2d 686 [1989]). However, the court erroneously failed to make any finding with respect to the defendants’ counterclaims. Therefore, the counterclaims must be severed and the matter remitted to the Supreme Court, Nassau County, for a new trial with respect to the counterclaims.
The defendants’ remaining contentions on their appeal are without merit.
Contrary to the plaintiffs contention on its cross appeal, the *659Supreme Court correctly dismissed the cause of action alleging violation of the Franchise Sales Act, based on the doctrine of in pari delicto. “The doctrine of in pari delicto mandates that the courts will not intercede to resolve a dispute between two wrongdoers. . . . The doctrine survives because it serves important public policy purposes. First, denying judicial relief to an admitted wrongdoer deters illegality. Second, in pari delicto avoids entangling courts in disputes between wrongdoers” (Kirschner v KPMG LLP, 15 NY3d 446, 464 [2010] [citations omitted]). The evidence established that the plaintiff knew that the defendants were offering to sell what amounted to a franchise as defined by General Business Law § 681 (3), to multiple persons at the same time that the plaintiff and the defendants entered into their agreement, and that the plaintiff was both aware of and complicit in the defendants’ violation of the Franchise Sales Act. Under the circumstances, the court properly applied the doctrine of in pari delicto, “not to favor [the] defendant, but as a matter of public policy” (Janke v Janke, 47 AD2d 445, 450 [1975], affd 39 NY2d 786 [1976]).
However, we agree with the plaintiff that the Supreme Court, which found that the defendant breached the parties’ agreement by delivering meat to the plaintiff in nonrefrigerated trucks and assigning a certain logo to the plaintiff without the authority to do so at the time that the agreement was entered into, erred in limiting the damages trial to the plaintiffs damages with respect to the cause of action alleging breach of contract based on the defendants’ failure to indemnify the plaintiff. Accordingly, upon remittal, a trial must be conducted on the issue of the plaintiffs damages for the defendant’s breach of the parties’ agreement by delivering meat to the plaintiff in nonrefrigerated trucks and assigning a certain logo to the plaintiff without the authority to do so at the time that the agreement was entered into.
Dickerson, J.E, Leventhal, Hall and Lott, JJ., concur.