Don't operate on multiple boundaries at once, instead keep collapsing from the first selected boundary.