I don’t know

Mr

I’m 24 and a first time mum. Getting pregnant to me is a miracle as I was told I can’t give birth. I had endometriosis. I’m in my 15th week now and the doctor just told me I have kidney infection because of the pregnancy. Should I be worried about my child ? What causes this infection ? And if I take medication will it not affect my child. Thank you