From: Josep Llodrà€ Date: Fri, 24 Feb 2012 12:09:00 +0000 (+0100) Subject: new commit: fix labelsDivStyles IE8 X-Git-Tag: v1.0.0~314^2~18^2~1 X-Git-Url: https://adrianiainlam.tk/git/?a=commitdiff_plain;h=3c23fa92c4e3f9f6ad0174dcf3e748d9676f3594;p=dygraphs.git new commit: fix labelsDivStyles IE8 --- diff --git a/dygraph.js b/dygraph.js index fed1cf4..2bc3f7a 100644 --- a/dygraph.js +++ b/dygraph.js @@ -1002,10 +1002,12 @@ Dygraph.prototype.createStatusMessage_ = function() { var div = document.createElement("div"); div.className = "dygraph-legend"; for (var name in messagestyle) { - try { - div.style[name] = messagestyle[name]; - } catch (e) { - console.warn("You are using unsupported css properties for your browser in labelsDivStyles"); + if (messagestyle.hasOwnProperty(name)) { + try { + div.style[name] = messagestyle[name]; + } catch (e) { + console.warn("You are using unsupported css properties for your browser in labelsDivStyles"); + } } } this.graphDiv.appendChild(div);