I can replace it with a thing that uses Iterators.getOnlyElement, maybe?