This one from 1990 says diet isn’t a risk factor, but it’s based on statistical, rather than biochemical, evidence. This one from a year earlier, also statistical, suggests the complete opposite. Then there’s one showing probiotic yoghurt reduced frequency; something that’s clearly dietary. I think it’s worth trying to find something more definitive.
Personally, I don’t see how diet can’t have an effect on just about any kind of infection or disease. How else can you positively influence the microbiota, the pH, the amount of available glucose etc in the vagina? Poor diets affect immunity and susceptibility to stress too. I guess it really depends what kind of diet we’re talking about.