Shark is one of the fish known to carry high mercury levels, and eating it a couple of times isn't likely to cause a specific problem for your baby, since mercury risk builds up with repeated, regular consumption rather than one or two servings.
Next Steps
Going forward, it's best to avoid shark, swordfish and king mackerel for the rest of your pregnancy, and stick to low-mercury options like rohu, tilapia, sardines or pomfret, which are safe in regular amounts.
Health Tips
Mention this to your obstetrician at your next antenatal visit, though it isn't a reason to worry on its own.