Skip to content

Commit 078640e

Browse files
committed
another potential issue with sharing notebooks
1 parent c8a5cd7 commit 078640e

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

src/packages/next/pages/share/public_paths/[...id].tsx

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -70,12 +70,14 @@ export async function getServerSideProps(context) {
7070

7171
const customize = await withCustomize({ context, props });
7272

73-
// Add full URL for social media sharing
74-
//
75-
customize.props.ogUrl = `${customize.props.customize.siteURL}${shareURL(
76-
id,
77-
relativePath,
78-
)}`;
73+
if (customize != null) {
74+
// Add full URL for social media sharing
75+
//
76+
customize.props.ogUrl = `${customize.props.customize.siteURL}${shareURL(
77+
id,
78+
relativePath,
79+
)}`;
80+
}
7981

8082
return customize;
8183
} catch (_err) {

0 commit comments

Comments
 (0)