From 778d79a3236c623a5985ef5bd9b5ac5c195ff8a9 Mon Sep 17 00:00:00 2001
From: Sam Wilkins
Date: Mon, 20 Jan 2020 18:18:25 -0500
Subject: layout key fix
---
src/client/views/nodes/DocumentContentsView.tsx | 2 +-
src/client/views/nodes/DocumentView.tsx | 1 -
2 files changed, 1 insertion(+), 2 deletions(-)
(limited to 'src')
diff --git a/src/client/views/nodes/DocumentContentsView.tsx b/src/client/views/nodes/DocumentContentsView.tsx
index 66886165e..867be287f 100644
--- a/src/client/views/nodes/DocumentContentsView.tsx
+++ b/src/client/views/nodes/DocumentContentsView.tsx
@@ -61,7 +61,7 @@ export class DocumentContentsView extends React.Componentawaiting layout
";
- const layout = Cast(this.layoutDoc[this.props.layoutKey], "string");
+ const layout = Cast(this.layoutDoc[StrCast(this.layoutDoc.layoutKey, "layout")], "string");
if (layout === undefined) {
return this.props.Document.data ?
"" :
diff --git a/src/client/views/nodes/DocumentView.tsx b/src/client/views/nodes/DocumentView.tsx
index c58362f6c..13aa049db 100644
--- a/src/client/views/nodes/DocumentView.tsx
+++ b/src/client/views/nodes/DocumentView.tsx
@@ -764,7 +764,6 @@ export class DocumentView extends DocComponent(Docu
if (typeof layoutKey === "string") {
return layoutKey;
}
- // return "layout";
const fallback = Cast(this.props.Document.layoutKey, "string");
return typeof fallback === "string" ? fallback : "layout";
}
--
cgit v1.2.3-70-g09d2