Wrong test in rke.keep.pairs. If the pair.ids to keep was empty, code was failing.