Bug 883059 - Check if the document is defunct before handling observer notifications. r=surkov, a=lsblakk