Skip to content

Commit

Permalink
fix: Change if condition to provide e2e test functionality. (#295)
Browse files Browse the repository at this point in the history
  • Loading branch information
srijanreddy98 authored Apr 27, 2021
1 parent d1b7732 commit cfb0f6f
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/lib/codemirror.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -169,8 +169,9 @@ export class CodemirrorComponent
}
}
codemirrorValueChanged(cm: Editor, change: EditorChangeLinkedList): void {
if (change.origin !== 'setValue') {
this.value = cm.getValue();
const cmVal = cm.getValue();
if (this.value !== cmVal) {
this.value = cmVal;
this.onChange(this.value);
}
}
Expand Down

0 comments on commit cfb0f6f

Please sign in to comment.