Bug 934487 - Fix "TypeError: this.markup is undefined" in devtools b-c runs; r=pbrosset
authorBrian Grinstead <bgrinstead@mozilla.com>
Tue, 05 Nov 2013 07:37:55 -0600
changeset 153593 20fb98a374ce044f63546c63c47ced9c10bd0317
parent 153592 cdafebd0eb7575e2f4b811fee4929c0db18889bc
child 153594 f66a6b1b0580df64908e09b827442a09629673b1
push id25595
push userryanvm@gmail.com
push dateTue, 05 Nov 2013 20:19:27 +0000
treeherdermozilla-central@2ada3a06d5e7 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerspbrosset
bugs934487
milestone28.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 934487 - Fix "TypeError: this.markup is undefined" in devtools b-c runs; r=pbrosset
browser/devtools/inspector/inspector-panel.js
--- a/browser/devtools/inspector/inspector-panel.js
+++ b/browser/devtools/inspector/inspector-panel.js
@@ -353,16 +353,19 @@ InspectorPanel.prototype = {
     this._getDefaultNodeForSelection().then(defaultNode => {
       if (this._destroyPromise) {
         return;
       }
       this.selection.setNodeFront(defaultNode, "navigateaway");
 
       this._initMarkup();
       this.once("markuploaded", () => {
+        if (this._destroyPromise) {
+          return;
+        }
         this.markup.expandNode(this.selection.nodeFront);
         this.setupSearchBox();
         this.emit("new-root");
       });
     });
   },
 
   _selectionCssSelector: null,