Disable click behavior for inactive link

Hi Oliver and thanks for this job.
Just a small optimization regarding the boring behavior when clicking on href="#" anchors.