Atiqkhan, there aren't any doctors on this forum, just interested people who have some knowledge. I don't know why that injection would be given; googling, it seems it's given very very early (like, at 2 weeks) to mothers who have suffered multiple miscarriages. This is really a question for your doctor to answer.
I will say, there's really no such thing as a "late heart beat" in an embryo. There are cases where they've misjudged the timing of the pregnancy and the baby is only 5 weeks or so along, instead of later when they'd expect a heartbeat. Sadly, the most common reason for not detecting a heartbeat in an 8 week pregnancy is that the pregnancy has failed and the baby is no longer viable.
I had two such early miscarriages, and understand the disappointment.
Can you schedule a consult with her doctor, so the two of you can understand the options and the recommendation?
Best wishes. Waiting for answers is very hard.
I do think sometimes a heartbeat can be 'missed' early on and that also, as rockrose says, the pregnancy didn't begin when people think it did and it began later so the pregnancy is less far along than thought. What is her doctor saying? Are they going to repeat the ultrasound soon?