fixed content not loadiing on some url

This commit is contained in:
Kim, Jimin 2021-08-16 23:29:22 +09:00
parent 60c4cd250f
commit 4c894c13aa

View file

@ -205,14 +205,15 @@ export default class Page extends React.Component<PageProps, PageState> {
} }
// fetch page // fetch page
const MapPost = map.posts[url]
const fetchedPage: FetchedPage = { const fetchedPage: FetchedPage = {
...map.posts[url], ...MapPost,
toc: undefined, toc: undefined,
content: "", content: "",
tags: [] as string[], tags: [] as string[],
} }
if (!fetchedPage) { if (!MapPost) {
_isUnsearchable = true _isUnsearchable = true
this.setState({ isUnsearchable: _isUnsearchable }) this.setState({ isUnsearchable: _isUnsearchable })