Bugfix to mate distance pruning.