Fix for jquery race when using firebug