Refactored ClickCounter.