Possible pregnancy

So I could be pregnant . Glow says af arrives 9/16. But I have a yeast infection. Doc gave me a pill and to use monistat but didnt tell me which one 1,3 or 7 days. I bought the 7 one. Im wondering if taking it for 7 days will hurt the possible baby.