- Downloads
Fix for canvases with no annotations
When using the Search feature, switching to a canvas without a search hit (i.e. no annotations targeting it), Mirador would run into a `TypeError` in the `setCurrentAnnotationsOnCurrentCanvas` saga. The underlying cause was that the code would try to select the first annotation for the current canvas, if the currently selected annotation was not targeting it. This, of course, failed when there were no annotations targeting the current canvas. This commit fixes it by adding a check for the presence of annotations for the current canvas before dispatching the `selectAnnotation` action.
Please sign in to comment