File tree 2 files changed +3
-3
lines changed
2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -65,7 +65,7 @@ var CodeMirror = createReactClass({
65
65
}
66
66
} ,
67
67
componentWillReceiveProps : function componentWillReceiveProps ( nextProps ) {
68
- if ( this . codeMirror && nextProps . value !== undefined && nextProps . value !== this . props . value && normalizeLineEndings ( this . codeMirror . getValue ( ) ) !== normalizeLineEndings ( nextProps . value ) ) {
68
+ if ( this . codeMirror && nextProps . value !== undefined && normalizeLineEndings ( this . codeMirror . getValue ( ) ) !== normalizeLineEndings ( nextProps . value ) ) {
69
69
if ( this . props . preserveScrollPosition ) {
70
70
var prevScrollPosition = this . codeMirror . getScrollInfo ( ) ;
71
71
this . codeMirror . setValue ( nextProps . value ) ;
@@ -133,4 +133,4 @@ var CodeMirror = createReactClass({
133
133
}
134
134
} ) ;
135
135
136
- module . exports = CodeMirror ;
136
+ module . exports = CodeMirror ;
Original file line number Diff line number Diff line change @@ -63,7 +63,7 @@ const CodeMirror = createReactClass({
63
63
}
64
64
} ,
65
65
componentWillReceiveProps : function ( nextProps ) {
66
- if ( this . codeMirror && nextProps . value !== undefined && nextProps . value !== this . props . value && normalizeLineEndings ( this . codeMirror . getValue ( ) ) !== normalizeLineEndings ( nextProps . value ) ) {
66
+ if ( this . codeMirror && nextProps . value !== undefined && normalizeLineEndings ( this . codeMirror . getValue ( ) ) !== normalizeLineEndings ( nextProps . value ) ) {
67
67
if ( this . props . preserveScrollPosition ) {
68
68
var prevScrollPosition = this . codeMirror . getScrollInfo ( ) ;
69
69
this . codeMirror . setValue ( nextProps . value ) ;
You can’t perform that action at this time.
0 commit comments