We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent aa49607 commit 1a2ee6aCopy full SHA for 1a2ee6a
1 file changed
src/diff-view.js
@@ -318,7 +318,7 @@ CodeMirrorDiffView.prototype.bind = function(container) {
318
if (!notice) {
319
notice = noticeTypes.lgpl;
320
}
321
- const editor = this._queryElement(`#${this.id}`);
+ const editor = this.el;
322
const splash = dom.getSplash({
323
notice,
324
left: (editor.offsetWidth - 300) / 2,
@@ -1200,7 +1200,7 @@ CodeMirrorDiffView.prototype._renderDiff = function(changes) {
1200
1201
CodeMirrorDiffView.prototype._queryElement = function(selector) {
1202
const cacheName = `_element:${selector}`;
1203
- const element = this[cacheName] || document.querySelector(selector);
+ const element = this[cacheName] || this.el.querySelector(selector);
1204
if (!this[cacheName]) {
1205
this[cacheName] = element;
1206
0 commit comments