Skip to content

Commit

Permalink
Merge pull request #17445 from pulsejet/pulsejet/fix-destroy
Browse files Browse the repository at this point in the history
Prevent errors in `AnnotationEditorUIManager.destroy` if the `altTextManager` is undefined
  • Loading branch information
Snuffleupagus authored Dec 20, 2023
2 parents 52ffd26 + 4d34107 commit 13da916
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/display/editor/tools.js
Original file line number Diff line number Diff line change
Expand Up @@ -778,7 +778,7 @@ class AnnotationEditorUIManager {
this.#activeEditor = null;
this.#selectedEditors.clear();
this.#commandManager.destroy();
this.#altTextManager.destroy();
this.#altTextManager?.destroy();
if (this.#focusMainContainerTimeoutId) {
clearTimeout(this.#focusMainContainerTimeoutId);
this.#focusMainContainerTimeoutId = null;
Expand Down

0 comments on commit 13da916

Please sign in to comment.