One Halloween treat may be even worse for you than you thought, and not because of sugar and empty calories.

In a new warning, the FDA says eating two ounces of black licorice per day for at least two weeks could prompt an irregular heart rhythm, called an arrhythmia, in adults 40 and older.

So is black licorice bad for you? When consumed in high amounts, glycyrrhizin, a sweet compound found in licorice root, causes potassium levels to temporarily drop, which in turn may cause abnormal heart rhythms, high blood pressure, swelling, lethargy and, in extreme cases, even heart failure. These issues normally go away once consumption stops.

Though the FDA's new black licorice warning is attracting attention, doctors have had concerns about the confection for a while. Back in 2012, for example, a group of researchers from Chicago's Mercy Hospital and Medical Center published a review in Endocrinology and Metabolism meant to serve as "a warning message that should be transmitted from physicians to patients to avoid excessive licorice intake as well as a message to the FDA to start regulating the use of this substance."

For fans of black licorice, the FDA recommends eating it in moderation, and contacting a doctor immediately if you experience irregular heart rhythms or muscle weakness after indulging. Licorice also may interact poorly with certain drugs such as aspirin, oral contraceptives and herbal supplements, so if you're taking any medications, you may want to speak with a doctor before digging in.

Even if you never eat black licorice, it's good to be aware of its health implications, as licorice root is often used as a flavoring and sweetening agent in soft drinks, teas and other consumer products. Conversely, a lot of black licorice candy sold in the U.S. uses little or no authentic licorice, instead relying on similar-tasting anise oil.

Just scan the ingredients before you indulge, and keep portion sizes in check.

This story originally appeared on Health.com.