diff options
author | bobzel <zzzman@gmail.com> | 2025-04-30 14:43:29 -0400 |
---|---|---|
committer | bobzel <zzzman@gmail.com> | 2025-04-30 14:43:29 -0400 |
commit | 0317a667a5d4a0f298522eeddb8afa96e7b7ecfc (patch) | |
tree | 2d66c3caa5c102a3ca78837b87e61c16fd07fc01 /src/client/views/linking/LinkMenuItem.tsx | |
parent | 9ec7df6af508eccdfda3a195a69c8bb1f86c41ea (diff) | |
parent | 2296c314be710f983d595de37c9d8039d73568a6 (diff) |
Merge branch 'master' into task_nodes_aarav
Diffstat (limited to 'src/client/views/linking/LinkMenuItem.tsx')
-rw-r--r-- | src/client/views/linking/LinkMenuItem.tsx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/views/linking/LinkMenuItem.tsx b/src/client/views/linking/LinkMenuItem.tsx index 1c92c3b0d..c984a7053 100644 --- a/src/client/views/linking/LinkMenuItem.tsx +++ b/src/client/views/linking/LinkMenuItem.tsx @@ -68,8 +68,8 @@ export class LinkMenuItem extends ObservableReactComponent<LinkMenuItemProps> { @computed get sourceAnchor() { const ldoc = this._props.linkDoc; if (this._props.sourceDoc !== ldoc.link_anchor_1 && this._props.sourceDoc !== ldoc.link_anchor_2) { - if (Doc.AreProtosEqual(DocCast(DocCast(ldoc.link_anchor_1).annotationOn), this._props.sourceDoc)) return DocCast(ldoc.link_anchor_1); - if (Doc.AreProtosEqual(DocCast(DocCast(ldoc.link_anchor_2).annotationOn), this._props.sourceDoc)) return DocCast(ldoc.link_anchor_2); + if (Doc.AreProtosEqual(DocCast(DocCast(ldoc.link_anchor_1)?.annotationOn), this._props.sourceDoc)) return DocCast(ldoc.link_anchor_1); + if (Doc.AreProtosEqual(DocCast(DocCast(ldoc.link_anchor_2)?.annotationOn), this._props.sourceDoc)) return DocCast(ldoc.link_anchor_2); } return this._props.sourceDoc; } |