diff --git a/CHANGELOG b/CHANGELOG index dbeca92..79a7ea4 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,3 +1,5 @@ +* Workaround a JavaScript exception in Opera. (Thomas Fuchs) + * Improve NodeList detection for Safari's $A function. (Garrett Smith, jddalton) * Use different tactic to sniff for Opera in order to avoid false positives in IE. (Tobie Langel, jddalton) diff --git a/src/dom.js b/src/dom.js index 89e17ee..87bdbac 100644 --- a/src/dom.js +++ b/src/dom.js @@ -597,7 +597,7 @@ Element.Methods = { element = forElement; do { - if (!Prototype.Browser.Opera || element.tagName.toUpperCase() == 'BODY') { + if (!Prototype.Browser.Opera || (element.tagName && (element.tagName.toUpperCase() == 'BODY'))) { valueT -= element.scrollTop || 0; valueL -= element.scrollLeft || 0; }