Skip to content
This repository has been archived by the owner on Oct 31, 2024. It is now read-only.

Commit

Permalink
fix(default-theme): catch api client rejection during fetching the fo…
Browse files Browse the repository at this point in the history
…oter navigation (#979)

Co-authored-by: mkucmus <maciejkucmus@gmail.com>
  • Loading branch information
patzick and mkucmus committed Jul 29, 2020
1 parent 1b67f1b commit 056cab2
Showing 1 changed file with 28 additions and 18 deletions.
46 changes: 28 additions & 18 deletions packages/default-theme/components/organisms/SwFooterNavigation.vue
Original file line number Diff line number Diff line change
Expand Up @@ -52,27 +52,37 @@ export default {
const column = ref(4)
onMounted(async () => {
const navigationResponse = await getStoreNavigation(
{
requestActiveId: "footer-navigation",
requestRootId: "footer-navigation",
searchCriteria: {
configuration: {
includes: {
category: ["seoUrls", "externalLink", "name", "id", "children"],
seo_url: ["pathInfo", "seoPathInfo"],
},
associations: [
{
name: "seoUrls",
try {
const navigationResponse = await getStoreNavigation(
{
requestActiveId: "footer-navigation",
requestRootId: "footer-navigation",
searchCriteria: {
configuration: {
includes: {
category: [
"seoUrls",
"externalLink",
"name",
"id",
"children",
],
seo_url: ["pathInfo", "seoPathInfo"],
},
],
associations: [
{
name: "seoUrls",
},
],
},
},
},
},
apiInstance
)
navigationLinks.value = getStoreNavigationRoutes(navigationResponse)
apiInstance
)
navigationLinks.value = getStoreNavigationRoutes(navigationResponse)
} catch (e) {
console.error("SwFooterNavigation:setup:onMounted", e)
}
})
const open = computed(() => {
Expand Down

0 comments on commit 056cab2

Please sign in to comment.