You must discuss your issue with your doctor if you have an STD. Before ending the pregnancy, your doctor would analyse your health. Antibiotics would be administered to you to treat any STD-related infections. Then, depending on the gestational phase, the doctor would either perform a medicinal abortion or a surgical abortion. Therefore, there won't be any STD-related contraindications to abortion.