Tidy Counter Mirror code.