diff --git a/cypress/e2e/workspace.spec.js b/cypress/e2e/workspace.spec.js index 2226d5b983..c8d048bc92 100644 --- a/cypress/e2e/workspace.spec.js +++ b/cypress/e2e/workspace.spec.js @@ -38,6 +38,15 @@ describe('Workspace', function() { cy.createTestFolder().as('testFolder') }) + it('Initializes the workspace without errors', function() { + cy.visitTestFolder({ + onBeforeLoad: win => cy.spy(win.console, 'error').as('consoleError'), + }) + cy.then(() => { + expect(this.consoleError).to.not.have.been.calledWithMatch('workspace') + }) + }) + it('Hides the workspace when switching to another folder', function() { cy.uploadFile('test.md', 'text/markdown', `${this.testFolder}/README.md`) cy.createFolder(`${this.testFolder}/subdirectory`) diff --git a/src/files.js b/src/files.js index 94c2d9d05d..67cadf325a 100644 --- a/src/files.js +++ b/src/files.js @@ -21,7 +21,6 @@ */ import { linkTo } from '@nextcloud/router' import { loadState } from '@nextcloud/initial-state' -import { registerFileListHeaders } from '@nextcloud/files' import { logger } from './helpers/logger.js' @@ -55,11 +54,6 @@ document.addEventListener('DOMContentLoaded', async () => { el: () => { return el }, })) } - - if (workspaceAvailable) { - const { FilesWorkspaceHeader } = await import('./helpers/files.js') - registerFileListHeaders(FilesWorkspaceHeader) - } }) OCA.Text = {