check for canvas element before trying to paint favicon badge
tweak dynamic favicon stuff to be compatible with firefox