title: How to detect class changing by DOMAttrModified
body: <p>I need to detect some class changing, i use for this DOMAttrModified, but something is wrong, what?</p>
  
  <pre><code>var first_img = $('body').find('li:first').find('img');
  
  first_img.on('DOMAttrModified',function(e){
      if (e.attrName === 'class') {
          if ($(this).hasClass('current-image')) {
              $(this).removeClass().addClass('previous-image');
          }
          console.log('log');
      }
  });
  </code></pre>
  
  <p>Thx for advice.</p>