title: jQuery: Uncaught TypeError: Object #<Object> has no method 'apply'
body: <p>I'm using jQuery 1.9.1 and trying to have an ajax query which is called every 5 seconds and updates some content.</p>
  
  <p>Using the code below, I get the following error in Chrome's console:</p>
  
  <pre><code>Uncaught TypeError: Object #&lt;Object&gt; has no method 'apply'
  </code></pre>
  
  <p>The line the error is on is line 3 of jquery.min.js</p>
  
  <pre><code>$(document).ready(function(){
        function getData()
        {
          $.getJSON('/ajax/pull', function(data){
            console.log(data.items);
  
            $("span").each(data.items, function(items){
              console.log(items);
              if($(this).attr('id') in items)
              {
                  console.log('here');
              }
            });
  
          });
        }
        window.setInterval(function() { getData(); } , 5000);
    });
  </code></pre>
  
  <p>I've looked through the other questions which have the same problem, but trying those fixes has no affect on my problem.</p>