diff --git a/app/components/SimpleEditor/elements/track_change/TrackChangesProvider.js b/app/components/SimpleEditor/elements/track_change/TrackChangesProvider.js index 63c653c5c1b9ee6b9a4bb9942bb316f57e5165f2..210bc087b92aa6bc98c71715cd99bcf104016eba 100644 --- a/app/components/SimpleEditor/elements/track_change/TrackChangesProvider.js +++ b/app/components/SimpleEditor/elements/track_change/TrackChangesProvider.js @@ -157,18 +157,16 @@ class TrackChangesProvider { // TODO -- handle multiple delete and add annotations getAnnotationByStatus (status) { const annotations = this.getAllExistingTrackAnnotations() - console.log('annos', annotations) - const annos = filter(annotations, (annotation) => { + const annotationsByStatus = filter(annotations, (annotation) => { return annotation.status === status }) - return annos[0] + return annotationsByStatus[0] } getExistingAnnotation () { const documentSession = this.getDocumentSession() const selectionState = documentSession.getSelectionState() const annotations = selectionState.getAnnotationsForType('track-change') - console.log(annotations) return annotations[0] }