Patched when defered for jquery compatibility.