Updated

Certain foods like chocolate, wine, and processed meats have long been linked to migraines, and while nitrates in those foods are often seen as the culprit, it's not entirely clear why some people are more susceptible to ensuing headaches than others, reports Quartz.

Now scientists are reporting in the journal mSystems that, thanks to an analysis of 2,200 people participating in the American Gut Project, they've found that people with migraines tend to have more oral bacteria that process nitrates, reports Refinery29.

More From Newser

This means that people suffering from migraines could be creating more nitric oxide, which has been linked to migraines, as they process those nitrates. Scientists next plan to study the diets of people with migraines to look for links between nitric oxide levels in their blood and migraines, which would help confirm that nitrate-processing oral bacteria are behind the headaches.

If that's true, we could eventually see a "magical probiotic mouthwash" that helps reshape oral bacteria to prevent migraines, reports the Guardian. In the meantime, researchers say, people who suspect that nitrates are behind their migraines should try to avoid them when possible—which could be difficult, considering they're also present in leafy greens.

(The source of this man's headache was highly unusual, and more than a little gross.)

This article originally appeared on Newser: Scientists May Have Found Migraine Trigger—in Our Mouths