From a281c646fd6c927554b00d84fe84dc3f7b93c9b1 Mon Sep 17 00:00:00 2001 From: "David M. Weigl" Date: Mon, 1 Mar 2021 17:08:19 +0100 Subject: [PATCH] fix error vis bug causing crashes when jumping with segment select menu --- src/containers/errorRibbonVis.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/containers/errorRibbonVis.js b/src/containers/errorRibbonVis.js index 70efd64..a7080e8 100644 --- a/src/containers/errorRibbonVis.js +++ b/src/containers/errorRibbonVis.js @@ -218,7 +218,7 @@ export default class ErrorRibbonVis extends Component { .map( (instant) => this.props.noteElementsForInstant(instant) ).flat() .map( (noteElement) => this.props.convertCoords(noteElement).x ) } - if(closestSuccessorScoretime) { + if(closestSuccessorScoretime && closestSuccessorScoretime.qstamp in this.props.instantsByScoretime[tl]) { successorNoteElementXPositions = this.props.instantsByScoretime[tl][closestSuccessorScoretime.qstamp] .map( (instant) => this.props.noteElementsForInstant(instant) ).flat() .map( (noteElement) => this.props.convertCoords(noteElement).x )