This is a great reason to go with a professional carpet cleaning company! Carpet that is wet cleaned should be dried within 12 hours. Carpet that is properly extraction-cleaned should not be wet long enough to mold.
If you decide to rent a cleaner and do it yourself, make sure to follow the instructions to avoid issues like mold.
A quick Google search of "carpet cleaners near me" should help you find a professional in your area to do the job for you.