title: finding property with true flag in an object
body: <p>I have an object with three properties. </p>
  
  <pre><code>$scope.badges = {'Full Service': false, 'Negotiable': true, 'Under Warranty': false};
  </code></pre>
  
  <p>How do i <code>extract OR find property</code> from it with <code>true</code> flag?</p>
  
  <p>Basically, i want to find property from this object having true flag and then assign it to another scope variable.</p>
  
  <p><strong>My HTML</strong></p>
  
  <pre><code>&lt;div ng-repeat="(badge,enabled) in badges" class="checkbox"&gt;
      &lt;label&gt;
          &lt;input type="checkbox" ng-model="badges[badge]" /&gt; {{badge}}
      &lt;/label&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p><strong>Angular Controller</strong></p>
  
  <pre><code>$scope.badges = {
      'Full Service History': false,
      'Negotiable': false,
      'Under Warranty': false,
      ' Urgent': false
  };
  </code></pre>
  
  <p><strong>I want to see which checkbox user has selected.</strong></p>