title: How to unsubscribe to a broadcast event in angularJS. How to remove function registered via $on
body: <p>I have registered my listener to a $broadcast event using $on function</p>
  
  <pre><code>$scope.$on("onViewUpdated", this.callMe);
  </code></pre>
  
  <p>and I want to un-register this listener based on a particular business rule. But my problem is that once it is registered I am not able to un-register it. </p>
  
  <p>Is there any method in AngularJS to un-register a particular listener? A method like $on that un-register this event, may be $off. So that based on the business logic i can say</p>
  
  <pre><code> $scope.$off("onViewUpdated", this.callMe);
  </code></pre>
  
  <p>and this function stop being called when somebody broadcast "onViewUpdated" event.</p>
  
  <p>Thanks</p>
  
  <p><strong>EDIT</strong>:
  I want to de-register the listener from another function. Not the function where i register it.</p>