How can I rescue overproofed bread?
Normally, you would not be doing a final proof overnight&mdash;that is, the proof that you have done to form the loaf.  Instead, you would do the first ferment or proof overnight, then form the loaf, let it have its final proof, and then bake it.

The dough won't be wasted, but you don't want to bake a formed loaf that has over-proofed and fallen.  This is because the gluten network will have collapsed and you will have a very poor structure and strange texture.  You will need to reknead the dough, form the loaf, and reproof it:

Per The Fresh Loaf, you can almost certainly just punch the dough down, and let it proof again.  It may actually have an improved flavor.

Cook's Illustrated concurs:

Using your fingertips, gently punch down the over-proofed dough and reshape it into a ball, then allow it to proof again for the recommended amount of time although it warns your final loaf may be about 20% smaller.