
619 F.3d 1272 (2010)
Gary William BAUDER, Petitioner-Appellee,
v.
DEPARTMENT OF CORRECTIONS STATE OF FLORIDA, Walter A. McNeil, Respondent-Appellant,
Secretary Florida Department of Children and Families, et al., Respondents.
No. 10-10657.
United States Court of Appeals, Eleventh Circuit.
September 13, 2010.
*1273 Janice L. Bergmann, Fed. Pub. Def., Ft. Lauderdale, FL, Kathleen M. Williams, Fed. Pub. Def., Miami, FL, for Williams.
Douglas J. Glaid, Bill McCollum, Richard L. Polin, Miami, FL, for Secretary, Fla Dept. of Corrections, Walter A. McNeil.
Before BARKETT and MARCUS, Circuit Judges, and HOOD,[*] Judge.
PER CURIAM:
The State of Florida appeals the district court's grant of Gary William Bauder's petition for habeas corpus under § 2254, in which the district court ruled that Bauder's criminal defense attorney was ineffective by misadvising Bauder regarding the possibility of being civilly committed as a result of pleading to a charge of aggravated stalking of a minor.[1]
In 2002, Bauder was charged with aggravated stalking of a minor, in violation of Fla. Stat. § 84.048(5). Bauder, who was represented by counsel, entered plea negotiations with the State immediately before his trial was set to begin and ultimately entered a plea of no contest, during which no mention was made of the possibility of civil commitment. Bauder was adjudicated guilty by the trial court and sentenced to 270 days in jail, one year of community control, and five years probation. Bauder appealed his conviction and sentence, which were affirmed by the appellate court. The Florida Supreme Court dismissed Bauder's subsequent petition for review.
Bauder then filed a motion for post-conviction relief pursuant to Fla. R.Crim. P. 3.850, in which he alleged that his attorney misadvised him by informing him, prior to his plea, that he could not face involuntary civil commitment under Florida law pursuant to Fla. Stat. § 394.910, et seq. The motion was summarily denied by the trial court, which misperceived Bauder's claim and instead addressed whether a failure to inform of the possibility for civil commitment could constitute ineffective assistance of counsel. The appellate court affirmed without opinion.
Bauder then filed this petition for habeas corpus pro se in federal district court in November 2006, likewise alleging, inter alia, that his counsel provided ineffective assistance of counsel by affirmatively telling him that pleading no contest to aggravated stalking would not subject him to civil commitment.[2] The district *1274 court initially denied the petition, construing Bauder's claim as one alleging that counsel failed to provide any advice on civil commitment. Bauder appealed, and this Court reversed and remanded to the district court for consideration of the claim that Bauder's counsel had affirmatively misadvised him. Bauder v. Dep't of Corr. of Fla., 333 Fed.Appx. 422 (11th Cir.2009). On remand, the district court appointed the Federal Public Defender as counsel for Bauder and accepted briefing from both parties. The magistrate judge issued a report and recommendation concluding that Bauder's petition should be granted, and, after a hearing on the State's objections to the magistrate's report, the district court granted Bauder's petition.[3]
In support of his petition for habeas corpus, Bauder submitted to the district court testimony from his counsel during the state criminal proceeding, in an affidavit, affirming that he "did not believe that the facts of this case could ever trigger a [civil commitment] proceeding against Mr. Bauder" and "[h]ad [he] any reason to believe that this particular case would trigger a Jimmy Ryce prosecution, [he] would have recommended proceeding to trial." He testified that he "did state both at the time of his plea bargain ... and subsequently thereafter to Mr. Bauder that [he] never believed that the facts [of Bauder's case] would be sufficient to trigger a [civil commitment] proceeding." Based on this testimony, which the district court found credible, the district court found that counsel affirmatively misadvised Bauder and concluded that the affirmative misadvice constituted deficient performance under Strickland v. Washington, 466 U.S. 668, 104 S.Ct. 2052, 80 L.Ed.2d 674 (1984). The district court also concluded that the misadvice prejudiced Bauder because (1) there was not overwhelming evidence of Bauder's guilt, (2) Bauder maintained his innocence of the crime throughout the state criminal proceeding, (3) Bauder averred in his pleadings that he would not have entered a plea had he been correctly advised about the potential for civil commitment, and (4) Bauder's attorney stated that he would have recommended that Bauder proceed to trial if he had any reason to believe that Bauder risked being civilly committed as a result of pleading.

DISCUSSION
The State raises two arguments on appeal. First, the State argues that the district court clearly erred in finding that Bauder's counsel misadvised Bauder on the collateral consequence of civil commitment stemming from his plea. Based on counsel's testimony described above, we cannot say that the district court's factual finding that counsel misadvised Bauder is clearly erroneous.
Second, the State argues that the district court erred in ruling that counsel's performance was deficient because the issue of whether Bauder would be subject to civil commitment was being litigated at the time of Bauder's plea. In support, the State cites a number of cases holding that attorneys cannot be found to have deficient performance when they fail to anticipate changes in law. While it is true that attorneys are not expected to anticipate changes in the law, this case does not involve a change in the law. Fla. Stat. § 394.910, et seq., was passed in 1999, *1275 years before Bauder's plea. Even if one could argue that the law was unclear, the Supreme Court has noted that when the law is unclear a criminal defense attorney must advise his client that the "pending criminal charges may carry a risk of adverse [collateral] consequences." Padilla v. Kentucky, ___ U.S. ___, 130 S.Ct. 1473, 1483, 176 L.Ed.2d 284 (2010).
Counsel's deficient performance was not his inability to anticipate a ruling on the interpretation of the Florida civil commitment statute. Rather, his deficient performance was his affirmative representation that Bauder would not be exposing himself to further detention past his sentence were Bauder to plead to the charge of aggravated stalking. Here, counsel did not tell Bauder that there was a possible risk of civil commitment, or that the law was unclear as to whether it could apply to Bauder, or that he simply did not know. Rather, counsel told Bauder that pleading to the criminal charge would not subject Bauder to civil commitment, and this constituted affirmative misadvice. For these reasons, the district court's grant of Bauder's petition for habeas corpus is
AFFIRMED.
NOTES
[*]  Honorable Joseph M. Hood, United States District Judge for the Eastern District of Kentucky, sitting by designation.
[1]  Florida's civil commitment statute, Fla. Stat. § 394.910, et seq., allows the State of Florida to indefinitely detain individuals adjudicated to be sexually violent predators beyond their period of criminal incarceration.
[2]  Bauder was incarcerated in December 2006 after admitting violations of the terms of his community control, and was set to be released on August 1, 2007. On July 30, 2007, however, the State of Florida filed a petition to have Bauder declared a sexually violent predator pursuant to Florida's civil commitment statute, which the state court granted, and Bauder has been involuntarily committed since then.
[3]  While federal courts typically must give deference to state court adjudications of claims in a habeas petition, see 28 U.S.C. § 2254(d)(1), such deference is not required if the state court failed to address the merits of a claim asserted by the petitioner. See Davis v. Sec'y for the Dep't of Corr., 341 F.3d 1310, 1313 (11th Cir.2003). The district court found that deference was not required because the state courts failed to address the merits of Bauder's claim. We agree.
