diff options
author | wolfbeast <mcwerewolf@gmail.com> | 2018-10-21 00:05:05 +0200 |
---|---|---|
committer | wolfbeast <mcwerewolf@gmail.com> | 2018-10-21 00:05:05 +0200 |
commit | 61a05da018433899a6991409eb5711bce0a901fb (patch) | |
tree | 856cae35089bb270c886316161d7a2303492d00d | |
parent | a9fbfba2ada6a6a87eacdd189129ebb0c8ec228a (diff) | |
download | UXP-61a05da018433899a6991409eb5711bce0a901fb.tar UXP-61a05da018433899a6991409eb5711bce0a901fb.tar.gz UXP-61a05da018433899a6991409eb5711bce0a901fb.tar.lz UXP-61a05da018433899a6991409eb5711bce0a901fb.tar.xz UXP-61a05da018433899a6991409eb5711bce0a901fb.zip |
Fix reference to undefined property warnings in toolkit's browser.xml.
-rw-r--r-- | toolkit/content/widgets/browser.xml | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/toolkit/content/widgets/browser.xml b/toolkit/content/widgets/browser.xml index e595c847d..a30ff1c43 100644 --- a/toolkit/content/widgets/browser.xml +++ b/toolkit/content/widgets/browser.xml @@ -389,10 +389,11 @@ <method name="getTabBrowser"> <body> <![CDATA[ - var tabBrowser = this.parentNode; - while (tabBrowser && tabBrowser.localName != "tabbrowser") - tabBrowser = tabBrowser.parentNode; - return tabBrowser; + for (let node = this.parentNode; node instanceof Element; node = node.parentNode) { + if (node.localName == "tabbrowser") + return node; + } + return null; ]]> </body> </method> |