Skip to content

Commit

Permalink
Fixed annotation error
Browse files Browse the repository at this point in the history
  • Loading branch information
arcuo committed May 9, 2023
1 parent 20c4f78 commit bc6666b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/event-listeners/onAnnotationChanged.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export default (documentViewerKey) => (annotations, action, info) => {
const selectAnnotationOnCreation = getHashParameters('selectAnnotationOnCreation', true);
if (selectAnnotationOnCreation) {
if (action === 'add' && !info.imported) {
const isFreeTextAnnot = annotations[0] instanceof window.Annotations.FreeTextAnnotation;
const isFreeTextAnnot = annotations[0] instanceof window.Core.Annotations.FreeTextAnnotation;
if (annotations.length > 0 && !annotations[0].InReplyTo && !isFreeTextAnnot) {
core.selectAnnotation(annotations[0]);
}
Expand Down

0 comments on commit bc6666b

Please sign in to comment.