My MIL won’t butt out

We were at the beach with my in-laws yesterday and after me being with my 5 year old in the water, my MIL said to my daughter to take off her Bathing suit. I told my LO she doesn’t have to, the sun is out and it’ll dry. Besides we’re going in the water again. MIL said, what if she gets a UTI. So my LO takes it off has just a towel over her, while she’s playing in the sand. It pissed me off so much, why MIL has to butt in the middle of it, then she sense the tension.