diff --git a/lib/client/editor.js b/lib/client/editor.js index 95d042ab..4313abc1 100644 --- a/lib/client/editor.js +++ b/lib/client/editor.js @@ -86,9 +86,15 @@ CloudCommander.Editor.CodeMirror = { /* fixing after first showinng CodeMirror bug */ var lCodeMirror = this.getByClass('CodeMirror'); if(lCodeMirror.length) { + var lDiv = lCodeMirror[0].getElementsByTagName('div'); - if(lDiv.length) - lDiv[0].style.cssText += lDiv.style.cssText + ';top:26px;left:57px'; + if(lDiv.length){ + lDiv = lDiv[0]; + + lDiv.style.cssText += + lDiv.style.cssText + + ';top:26px;left:57px'; + } } lCloudEditor && (lCloudEditor.className = '');