Pain meds and breastfeeding

ma

Pediatrician said I shouldn’t breastfeed while on norco and I’m also on ibuprofen. My question is if my last pill was at 1:30 today and I don’t plan on taking anymore so that I can breastfeed , when would be safe to? Currently don’t have a pump to pump and dump.. would I have to wait 24hours? Tia

6 days old