Breastfeeding while pregnant

I recently found out I’m pregnant and still breastfeeding my 15 months old baby boy..my dr told me to stop but I can’t!! He cries so bad I can’t handle it..has anyone breastfeed beeing pregnant? Was everything ok?