Also check that path is defined
This commit is contained in:
parent
f6d5fef8c3
commit
3052f6ecfa
1 changed files with 2 additions and 2 deletions
|
|
@ -21,7 +21,7 @@ export default class extends React.Component {
|
||||||
for (i = 0, len = ref.length; i < len; i++) {
|
for (i = 0, len = ref.length; i < len; i++) {
|
||||||
page = ref[i];
|
page = ref[i];
|
||||||
title = ((ref1 = page.data) != null ? ref1.title : void 0) || page.path;
|
title = ((ref1 = page.data) != null ? ref1.title : void 0) || page.path;
|
||||||
if (page.path !== "/" && !((ref2 = page.data) != null ? ref2.draft : void 0)) {
|
if (page.path && page.path !== "/" && !((ref2 = page.data) != null ? ref2.draft : void 0)) {
|
||||||
pageLinks.push(
|
pageLinks.push(
|
||||||
<li
|
<li
|
||||||
key={page.path}
|
key={page.path}
|
||||||
|
|
@ -59,6 +59,6 @@ export default class extends React.Component {
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
</DocumentTitle>
|
</DocumentTitle>
|
||||||
);
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue