CORE-5464 minor refactor.