Diet can also be a factor with both, as can the thyroid or other hormonal problems.
Sinus congestion, and the medication
for it, can also cause these problems, and can also be caused by something you're eating or exposed to, and is a sign of an overactive immune system. So you've got a constellation of stuff going on, and it would be good if you could get to the root cause, though we all know how hard that is to do.