title: How to remove a UITabBar badge after the user clicks another tab?
body: <p>I want to remove a badge as soon as the user clicks another tab. I am trying to do:</p>
  
  <pre><code>- (void)viewDidDisappear:(BOOL)animated {
      [super viewDidDisappear:animated];
  
      UITabBarItem *tbi = (UITabBarItem *)self.tabController.selectedViewController.tabBarItem;
      tbi.badgeValue = nil;
  }
  </code></pre>
  
  <p>But it doesn't work.</p>