Prevent double execution of a jquery function?
<p>I've set up the this function to show one div at a time that has been targeted in the navigation.</p>

<pre><code>$(document).ready(function(){
    $('.div1, .div2').hide();
    $("nav a").hover(function () {  
    var name= this.name;
    $("."+name).fadeIn().siblings().hide();
   });  
});
</code></pre>

<p>This function works, but if I'm switching very fast beteween my nav element it can happen that div1 and div2 appear at the same time. </p>

<p>How can I prevent this from happening?</p>

<p>Thank you.</p>
