mirror of
https://github.com/oceanprotocol/docs.git
synced 2024-11-26 19:49:26 +01:00
Issue-#545: Add try-catch block
This commit is contained in:
parent
81faf61201
commit
efb1b20e6d
@ -179,13 +179,19 @@ exports.createPages = ({ graphql, actions }) => {
|
||||
}
|
||||
|
||||
const createSearchPage = async (createPage) => {
|
||||
const template = path.resolve('./src/components/Search/SearchComponent.jsx')
|
||||
const slug = `/search/`
|
||||
try {
|
||||
const pageTemplate = path.resolve(
|
||||
'./src/components/Search/SearchComponent.jsx'
|
||||
)
|
||||
const url = `/search/`
|
||||
|
||||
createPage({
|
||||
path: slug,
|
||||
component: template
|
||||
})
|
||||
createPage({
|
||||
path: pageTemplate,
|
||||
component: url
|
||||
})
|
||||
} catch (error) {
|
||||
console.log(error.message)
|
||||
}
|
||||
}
|
||||
|
||||
const createDeploymentsPage = async (createPage) => {
|
||||
|
Loading…
Reference in New Issue
Block a user