I don't really know anything about straight irons but I would imagine it's not so much that it's bad for the baby in any way, more just that your hair tends to dry out and suffer and often fall out when pregnant, and straight ironing could therefore cause more damage as the hair is already weak.
So the problem would not be with the pregnancy, but with the condition and strength of your hair.