aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/collections/CollectionSchemaCells.tsx
diff options
context:
space:
mode:
authorMelissa Zhang <mzhang19096@gmail.com>2020-08-15 00:42:50 -0700
committerMelissa Zhang <mzhang19096@gmail.com>2020-08-15 00:42:50 -0700
commit7652011ff230e1de8a698a1326ba2c621d9f482a (patch)
treee5e22f7c30834495bf2af06fe12d62b871b1cc4c /src/client/views/collections/CollectionSchemaCells.tsx
parentbb2a9c80d1512d120d95dc1f603d1e3729dbb981 (diff)
parent49db347deac85eb3ea3c1e4297758cd6b18e0225 (diff)
merge with master
Diffstat (limited to 'src/client/views/collections/CollectionSchemaCells.tsx')
-rw-r--r--src/client/views/collections/CollectionSchemaCells.tsx5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/client/views/collections/CollectionSchemaCells.tsx b/src/client/views/collections/CollectionSchemaCells.tsx
index 24088575a..81b63cbcd 100644
--- a/src/client/views/collections/CollectionSchemaCells.tsx
+++ b/src/client/views/collections/CollectionSchemaCells.tsx
@@ -82,9 +82,8 @@ export class CollectionSchemaCell extends React.Component<CellProps> {
const doc = Doc.GetProto(this.props.rowProps.original);
const aliasdoc = await SearchUtil.GetAliasesOfDocument(doc);
if (aliasdoc.length > 0) {
- const targetContext = Cast(aliasdoc[0].context, Doc) as Doc;
- console.log(StrCast(targetContext.title));
- runInAction(() => this.contents = StrCast(targetContext.title));
+ const targetContext = Cast(aliasdoc[0].context, Doc, null);
+ targetContext && runInAction(() => this.contents = StrCast(targetContext.title));
}
}