diff options
author | Fawn <fangrui_tong@brown.edu> | 2019-06-13 18:07:35 -0400 |
---|---|---|
committer | Fawn <fangrui_tong@brown.edu> | 2019-06-13 18:07:35 -0400 |
commit | 8bcd3567df7c49523638f0b935ecd09b1acad45d (patch) | |
tree | 2ab4f174a1f19c1b79f9e3f0b634a2cb6a2463fb /src/client/documents/Documents.ts | |
parent | 0d0782362d4549b80c27c3ce5d8439c2f6fa4d7b (diff) |
cannot create the same link twice
Diffstat (limited to 'src/client/documents/Documents.ts')
-rw-r--r-- | src/client/documents/Documents.ts | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/client/documents/Documents.ts b/src/client/documents/Documents.ts index 9517cbbda..9cb41aecc 100644 --- a/src/client/documents/Documents.ts +++ b/src/client/documents/Documents.ts @@ -86,6 +86,7 @@ const delegateKeys = ["x", "y", "width", "height", "panX", "panY"]; export namespace DocUtils { export function MakeLink(source: Doc, target: Doc) { + if (LinkManager.Instance.doesLinkExist(source, target)) return; // let protoSrc = source.proto ? source.proto : source; // let protoTarg = target.proto ? target.proto : target; UndoManager.RunInBatch(() => { |