I am 2 months pregnant and my dogs have fleas what can I use on them and not hurt my baby?

Fleas in pregnancy. I found this information on the internet: capstar: "unlike topical and spot-on flea products, capstar is a tiny pill which is administered orally to dogs, cats, puppies, and kittens as long as they are 4 weeks or older and weigh more than 2 pounds. Capstar is also safe for pregnant or nursing animals. The main ingredient in capstar is nitenpyram which is safe for mammals.