Can Diarrhoea affect baby?

The past couple of nights I’ve had really bad diarrhoea after dinner. I had an upset tummy last week too!

Will this affect the baby? I’m 7 weeks pregnant