Skip to content

Commit

Permalink
Merge pull request #37206 from nextcloud/fix-skip-recommended-apps-wr…
Browse files Browse the repository at this point in the history
…ong-url

fix: wrong redirect when skipping recommended apps
  • Loading branch information
ChristophWurst authored Apr 26, 2023
2 parents 4c34be3 + e025cf0 commit defbd23
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 11 deletions.
11 changes: 3 additions & 8 deletions core/src/components/setup/RecommendedApps.vue
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,7 @@
<NcButton v-if="showInstallButton"
type="tertiary"
role="link"
href="defaultPageUrl"
@click="goTo(defaultPageUrl)">
:href="defaultPageUrl">
{{ t('core', 'Skip') }}
</NcButton>

Expand Down Expand Up @@ -115,7 +114,6 @@ const recommended = {
},
}
const recommendedIds = Object.keys(recommended)
const defaultPageUrl = loadState('core', 'defaultPageUrl')

export default {
name: 'RecommendedApps',
Expand All @@ -129,7 +127,7 @@ export default {
loadingApps: true,
loadingAppsError: false,
apps: [],
defaultPageUrl,
defaultPageUrl: loadState('core', 'defaultPageUrl')
}
},
computed: {
Expand Down Expand Up @@ -180,7 +178,7 @@ export default {
.then(() => {
logger.info('all recommended apps installed, redirecting …')

window.location = defaultPageUrl
window.location = this.defaultPageUrl
})
.catch(error => logger.error('could not install recommended apps', { error }))
},
Expand Down Expand Up @@ -210,9 +208,6 @@ export default {
}
return !!recommended[appId].hidden
},
goTo(href) {
window.location.href = href
},
},
}
</script>
Expand Down
4 changes: 2 additions & 2 deletions dist/core-recommendedapps.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit defbd23

Please sign in to comment.