Usually, at least I my experience, the adoption agency knows of any drug use done during pregnancy and adoptive parents are fully aware of the situation.
Adoptive agencies definitely don't hide this Information, and the adoption process is very in-depth. So before adopting a child, you would actually know the situation the baby comes from and whether the birth mom did drugs while pregnant.
The only thing they don't usually know for sure I how it might impact the child as they grow up. But there are plenty of adoptive parents who want to provide homes for these children -- I know several myself, both adoptive parents and their children who who's birth mom did drugs while pregnant. There wasn't any secrets or unknowns at all.
Thanks for your comment and curiosity!