
    Henry HILSENROTH, Appellant, v. Alfred KESSLER, individually, Robert J. Dominix, Richard Kessler, as Personal Representative of the Estate of Sydney Kessler, and Benjamin Budowsky, Appellees.
    No. 82-983.
    District Court of Appeal of Florida, Third District.
    Dec. 6, 1983.
    As Modified on Denial of Rehearing March 26, 1984.
    
      Lapidus & Stettin and Herbert Stettin, Miami, for appellant.
    Ress, Gomez, Rosenberg & Howland and Sheldon Rosenberg, James A. Horland, Ro-bey & Pelstring and R. James Pelstring, Miami, for appellees.
    Before HENDRY, NESBITT and BAS-KIN, JJ.
   NESBITT, Judge.

In September, 1972, Hilsenroth contracted to purchase land from Alfred Kessler as trustee for himself, Budowsky, Dominix, and Sydney Kessler, now deceased. The express purpose was to build apartment houses. The contract allowed Hilsenroth to rescind before closing if the property was subject to a moratorium on the issuance of building permits. Thereafter, on December 1, 1972, the Dade County Pollution Control Department issued a moratorium on building permits which prohibited further connections to the sewer system. The moratorium lasted until December, 1978, and applied to all of the property being sold to Hilsenroth. Unaware of this restriction, Hilsenroth closed on the property in June, 1973. He paid approximately $200,000 in return for which he received 2.5 acres free and clear of mortgages. The remaining property was acquired subject to an existing first mortgage and individual promissory notes, in favor of each of the four members of the selling group, secured by a single purchase money second mortgage.

In September, 1973, Hilsenroth learned of the sewer moratorium from his engineers. One month later, he sought a declaratory decree (the 1973 suit) concerning his right to a moratorium in principal and interest under the terms of the second mortgage. Hilsenroth prevailed at trial and on appeal. Kessler v. Hilsenroth, 325 So.2d 72 (Fla. 3d DCA 1975). At a hearing in this case on June 20, 1974, Hilsenroth first learned from Kessler’s testimony that Kessler had known of the moratorium prior to closing.

At the end of 1975, Hilsenroth. filed suit to rescind the contract to purchase the property on the grounds of fraud and deceit. Only one member of the selling group, Dominix, counterclaimed for enforcement of his note and foreclosure on his second mortgage. That counterclaim was abated until the end of the sewer moratorium. All of the sellers obtained a summary judgment on Hilsenroth’s claim for rescission upon the theory that by seeking and obtaining a moratorium in payments due under the mortgage in the 1973 suit, Hilsenroth had elected his remedies, had chosen to affirm the contract, and could not rescind. This was affirmed on appeal. Hilsenroth v. Kessler, 353 So.2d 874 (Fla. 3d DCA 1977), cert. denied, 366 So.2d 881 (Fla.1978).

The moratorium ended in 1978. In April, 1979, the members of the selling group (excluding Dominix who had filed a counterclaim for foreclosure in the 1975 suit) filed a suit to foreclose on their mortgage. Hilsenroth counterclaimed seeking money damages for fraud and deceit and breach of contractual warranties. In February, 1980, Hilsenroth filed an amendment to his 1975 suit seeking the same relief as in his counterclaim in the 1979 foreclosure suit. The 1975 and 1979 suits were consolidated.

At a nonjury trial, the judge found that Hilsenroth was entitled to compensatory damages for breach of contractual warranties and for fraud and deceit. Punitive damages were imposed against Alfred Kes-sler as the one whom the court found had withheld the information regarding the moratorium. Compensatory damages were limited to architectural fees incurred from the closing date until the suit was filed for declaratory relief. The trial court specifically denied recovery under benefit of the bargain or out-of-pocket theories of recovery because Hilsenroth failed to mitigate damages. The court further determined that the selling group was entitled to foreclose on its purchase money mortgage and recover the principal, interest, and real estate taxes paid by it. Hilsenroth was not permitted to set off the compensatory and punitive awards against the mortgage indebtedness. Finally, the court determined that the sellers were not entitled to attorneys’ fees and costs. Both sides appeal.

We first consider the cross-appeal by the sellers in which they allege that the damage award in favor of Hilsenroth was improper. The compensatory damages award against Dominix was based on the 1980 amendment to the complaint for rescission originally filed in 1975. The 1975 case resulted in a summary judgment in favor of the sellers. This terminated the trial court’s jurisdiction over the complaint, General Capital Corp. v. Tel Service Co., 212 So.2d 369 (Fla. 2d DCA 1968), and thus no amendment to the complaint could be made.

With respect to the remaining sellers, affirmative relief was granted to Hil-senroth based on the 1980 amended complaint as well as Hilsenroth’s counterclaim to these sellers’ foreclosure action. We have already determined that the summary judgment in favor of the sellers in the 1975 suit left the trial court without jurisdiction to consider an amended complaint against Dominix. The same is true with respect to these defendants and thus the purchaser’s recovery for compensatory and punitive damages on this basis must be reversed.

Furthermore, as a claim for affirmative relief, Hilsenroth’s counterclaim for compensatory damages would have been barred by the applicable statute of limitations. § 95.11(3)(j), Fla.Stat. (1981). Nonetheless, it is an established principle that even after an action for affirmative relief is barred by the statute of limitations, it may be asserted by way of defense to a claim against him. Payne v. Nicholson, 100 Fla. 1459, 131 So. 324 (1930); Horace Mann Insurance Co. v. DeMirza, 312 So.2d 501 (Fla. 3d DCA 1975). Thus, we conclude that Hilsenroth is not precluded from raising these issues as affirmative defenses in reduction of the aggregate unpaid balance on the mortgages.

Accordingly, we must remand to the trial court for a determination of the amount of reduction which the purchaser is entitled to because of the sellers’ fraud. In doing so, we direct that the trial court should allow a setoff for oút-of-pocket expenses or damages for loss of the benefit of the bargain. See DuPuis v. 79th Street Hotel, Inc., 231 So.2d 532 (Fla. 3d DCA 1970), cert. denied, 238 So.2d 105 (Fla.1970). We reject the sellers’ contention that Hilsenroth’s failure to mitigate damages by building his own sewage plant precluded damages based on these theories. Were we to require that such action be taken by the purchaser, we would be rewriting the parties’ contract which contemplated a governmental sewage plant. See Richard v. A. Waldman & Sons, Inc., 155 Conn. 343, 232 A.2d 307 (1967) (parties are not required to give up a substantial right of their own to minimize the loss). Nor do we find that Hilsenroth was precluded from recovering these damages because of his earlier declaratory judgment action. Levey v. Getelman, 408 So.2d 663 (Fla. 3d DCA 1981).

When the fraud which has been perpetrated on Hilsenroth has been rectified by reduction of the unpaid balance of the promissory notes in accordance with our decision, then the malefactors are entitled to the satisfaction of their rights under the contract. Schwartz v. Zaconick, 68 So.2d 173, 176 (Fla.1953). This would include foreclosure if an unpaid balance remains after the setoff, and costs and attorneys’ fees as provided by the contract, but does not permit the sellers to foreclose against unpaid ad valorem taxes. Bie v. Hulet, 149 Fla. 227, 5 So.2d 457 (1942); Blue Heron Land Co. v. Brown, 98 Fla. 1238, 125 So. 369 (1930).

For the foregoing reasons, the judgment in favor of Hilsenroth for compensatory and punitive damages is reversed. That portion of the trial court order allowing foreclosure is remanded to determine the aggregate unpaid balance of the mortgage including principal, interest, costs, and attorneys’ fees after the setoff allowed the buyer under either a benefit of the bargain or out-of-pocket theory of recovery.

Reversed and remanded with directions. 
      
      . Hilsenroth sought recovery for sums spent to acquire the property, for its maintenance while he waited for the moratorium to be lifted and the claimed benefit of the bargain contracted.
     
      
      . Had Hilsenroth filed a separate lawsuit against Dominix in 1980, it would have been barred by the statute of limitations.
     
      
      . The fact that Hilsenroth was not required to mitigate his damages by building his own sewage plant does not relieve him of the duty to keep his damages as low as reasonably possible, see Richard v. A. Waldman & Sons, Inc., 232 A.2d at 310-11. Accordingly, except as noted, the trial court is free to apply the doctrine of mitigation of damages, if applicable.
     
      
      . The appellee is correct, however, in his claim that the declaratory judgment would bar Hilsen-roth’s claim for cancellation. See Levey (ratification of contract bars claim for rescission).
     