Phlegm that tastes like infection

Hi all, does anyone else notice that they can tell when they've got a lung infection because your phlegm tastes different when you cough it up? I always find I can so wanted to hear everyone else's experiences! Wishing everyone a healthy winter xx