aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/nodes/FormattedTextBox.tsx
diff options
context:
space:
mode:
authorkimdahey <claire_kim1@brown.edu>2019-08-28 15:15:49 -0400
committerkimdahey <claire_kim1@brown.edu>2019-08-28 15:15:49 -0400
commit2f81ba96ac9c2aecbb9d610ecdc7d35335931e38 (patch)
tree8a282dd07ca3f93c4873e5f76e3616723e705aea /src/client/views/nodes/FormattedTextBox.tsx
parent65eecfc4295512f4f4fc6441f888c50f42adaced (diff)
stil.lllll working
Diffstat (limited to 'src/client/views/nodes/FormattedTextBox.tsx')
-rw-r--r--src/client/views/nodes/FormattedTextBox.tsx9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/client/views/nodes/FormattedTextBox.tsx b/src/client/views/nodes/FormattedTextBox.tsx
index 33f585279..33edcc7f6 100644
--- a/src/client/views/nodes/FormattedTextBox.tsx
+++ b/src/client/views/nodes/FormattedTextBox.tsx
@@ -183,13 +183,10 @@ export class FormattedTextBox extends DocComponent<(FieldViewProps & FormattedTe
if (linkIndex !== -1) {
if (guid === marks[linkIndex].attrs.guid) {
return node;
- } else {
- console.log(marks[linkIndex].attrs.href);
+ } else if (href && href === marks[linkIndex].attrs.href) { // retroactively fixing old in-text links by adding guid
+ marks[linkIndex].attrs.guid = guid;
+ return node;
}
- // else if (href === marks[linkIndex].attrs.href) {
- // marks[linkIndex].attrs.guid = guid;
- // return node;
- // }
}
return undefined;
}