What to do with mid-ocean ridge in collision?


The two continents at the top are about to collide into each other, and the oceanic crust connected to them has a mid ocean ridge in between.
My question is; What happens to the mid-ocean ridge here? Does it get deleted, push the continents apart, or something else? Does this even fit within requirements for realism?

My experience with this has come from Worldbuilding Pasta, and I can’t seem to find an answer online.

A mid-ocean ridge can be subducted, because subduction is often faster than the rifting of the ridge. As soon as the ridge is fully subducted, the oceanic plate can no longer grow at all and will eventually be fully subducted. Then your continents collide.