@@ -184,19 +184,20 @@ import ListViewIcon from 'vue-material-design-icons/FormatListBulletedSquare.vue
184184import ViewGridIcon from ' vue-material-design-icons/ViewGrid.vue'
185185
186186import { action as sidebarAction } from ' ../actions/sidebarAction.ts'
187- import { getSummaryFor } from ' ../utils/fileUtils.ts'
188- import { humanizeWebDAVError } from ' ../utils/davUtils.ts'
189187import { useFileListWidth } from ' ../composables/useFileListWidth.ts'
190- import { useFilesStore } from ' ../store/files.ts'
191- import { useFiltersStore } from ' ../store/filters.ts'
192188import { useNavigation } from ' ../composables/useNavigation.ts'
193- import { usePathsStore } from ' ../store/paths.ts'
194189import { useRouteParameters } from ' ../composables/useRouteParameters.ts'
195190import { useActiveStore } from ' ../store/active.ts'
191+ import { useFilesStore } from ' ../store/files.ts'
192+ import { useFiltersStore } from ' ../store/filters.ts'
193+ import { usePathsStore } from ' ../store/paths.ts'
196194import { useSelectionStore } from ' ../store/selection.ts'
197195import { useUploaderStore } from ' ../store/uploader.ts'
198196import { useUserConfigStore } from ' ../store/userconfig.ts'
199197import { useViewConfigStore } from ' ../store/viewConfig.ts'
198+ import { humanizeWebDAVError } from ' ../utils/davUtils.ts'
199+ import { getSummaryFor } from ' ../utils/fileUtils.ts'
200+ import { defaultView } from ' ../utils/filesViews.ts'
200201import BreadCrumbs from ' ../components/BreadCrumbs.vue'
201202import DragAndDropNotice from ' ../components/DragAndDropNotice.vue'
202203import FilesListVirtual from ' ../components/FilesListVirtual.vue'
@@ -609,14 +610,14 @@ export default defineComponent({
609610 const currentView = this .currentView
610611
611612 if (! currentView ) {
612- logger .debug (' The current view doesn \' t exists or is not ready.' , { currentView })
613+ logger .debug (' The current view does not exists or is not ready.' , { currentView })
613614
614615 // If we still haven't a valid view, let's wait for the page to load
615616 // then try again. Else redirect to the default view
616617 window .addEventListener (' DOMContentLoaded' , () => {
617618 if (! this .currentView ) {
618619 logger .warn (' No current view after DOMContentLoaded, redirecting to the default view' )
619- window .OCP .Files .Router .goToRoute (null , { view: ' files ' })
620+ window .OCP .Files .Router .goToRoute (null , { view: defaultView () })
620621 }
621622 }, { once: true })
622623 return
0 commit comments