summaryrefslogtreecommitdiffstats
path: root/dom/base/nsDocument.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'dom/base/nsDocument.cpp')
-rw-r--r--dom/base/nsDocument.cpp12
1 files changed, 0 insertions, 12 deletions
diff --git a/dom/base/nsDocument.cpp b/dom/base/nsDocument.cpp
index 0f663636f..afe88a454 100644
--- a/dom/base/nsDocument.cpp
+++ b/dom/base/nsDocument.cpp
@@ -4512,18 +4512,6 @@ nsDocument::SetScriptGlobalObject(nsIScriptGlobalObject *aScriptGlobalObject)
mLayoutHistoryState = nullptr;
SetScopeObject(aScriptGlobalObject);
mHasHadDefaultView = true;
-#ifdef DEBUG
- if (!mWillReparent) {
- // We really shouldn't have a wrapper here but if we do we need to make sure
- // it has the correct parent.
- JSObject *obj = GetWrapperPreserveColor();
- if (obj) {
- JSObject *newScope = aScriptGlobalObject->GetGlobalJSObject();
- NS_ASSERTION(js::GetGlobalForObjectCrossCompartment(obj) == newScope,
- "Wrong scope, this is really bad!");
- }
- }
-#endif
if (mAllowDNSPrefetch) {
nsCOMPtr<nsIDocShell> docShell(mDocumentContainer);