It is safest to stear clear....and keep in mind that even once the infection is clear in your friend's dog, you will want to avoid that dog's outdoor area and not visit at his house. Whipworms pass eggs in the dog's feces and these can live in moist soil for many many months, if not years.
So while your dog is not at much risk of getting infection from the other dog even right now - what you want to avoid is having that dog go to the bathroom on your property, or your dog visit his property. Keep in mind that to get infection, the worms must be ingested so not a huge risk.