diff options
author | John Molakvoæ <skjnldsv@protonmail.com> | 2023-04-07 08:42:56 +0200 |
---|---|---|
committer | John Molakvoæ <skjnldsv@protonmail.com> | 2023-04-11 11:56:04 +0200 |
commit | e3f575ba7a600971278a68eeedd123ae8afcd4b8 (patch) | |
tree | ce0ca02d5f57ca6a20b12295551e812d040d7a04 | |
parent | a16703d18183aa34a7e6ffcb9c9cb3756cfb0c2e (diff) | |
download | nextcloud-server-e3f575ba7a600971278a68eeedd123ae8afcd4b8.tar.gz nextcloud-server-e3f575ba7a600971278a68eeedd123ae8afcd4b8.zip |
fix(files): update @nextcloud/files and fix event store update
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
-rw-r--r-- | apps/files/src/store/files.ts | 20 | ||||
-rw-r--r-- | apps/files/src/store/paths.ts | 4 | ||||
-rw-r--r-- | apps/files/src/store/userconfig.ts | 4 | ||||
-rw-r--r-- | package-lock.json | 19 | ||||
-rw-r--r-- | package.json | 2 |
5 files changed, 22 insertions, 27 deletions
diff --git a/apps/files/src/store/files.ts b/apps/files/src/store/files.ts index f3289378096..27b6b12f348 100644 --- a/apps/files/src/store/files.ts +++ b/apps/files/src/store/files.ts @@ -81,34 +81,26 @@ export const useFilesStore = () => { Vue.set(this.roots, service, root) }, - onCreatedNode() { - // TODO: do something - }, - onDeletedNode(node: Node) { this.deleteNodes([node]) }, - - onMovedNode() { - // TODO: do something - }, } }) const fileStore = store() // Make sure we only register the listeners once - if (!fileStore.initialized) { - subscribe('files:file:created', fileStore.onCreatedNode) + if (!fileStore._initialized) { + // subscribe('files:file:created', fileStore.onCreatedNode) subscribe('files:file:deleted', fileStore.onDeletedNode) - subscribe('files:file:moved', fileStore.onMovedNode) + // subscribe('files:file:moved', fileStore.onMovedNode) // subscribe('files:file:updated', fileStore.onUpdatedNode) - subscribe('files:folder:created', fileStore.onCreatedNode) + // subscribe('files:folder:created', fileStore.onCreatedNode) subscribe('files:folder:deleted', fileStore.onDeletedNode) - subscribe('files:folder:moved', fileStore.onMovedNode) + // subscribe('files:folder:moved', fileStore.onMovedNode) // subscribe('files:folder:updated', fileStore.onUpdatedNode) - fileStore.initialized = true + fileStore._initialized = true } return fileStore diff --git a/apps/files/src/store/paths.ts b/apps/files/src/store/paths.ts index b0f9552f606..8e458eb87b0 100644 --- a/apps/files/src/store/paths.ts +++ b/apps/files/src/store/paths.ts @@ -56,13 +56,13 @@ export const usePathsStore = () => { const pathsStore = store() // Make sure we only register the listeners once - if (!pathsStore.initialized) { + if (!pathsStore._initialized) { // TODO: watch folders to update paths? // subscribe('files:folder:created', pathsStore.onCreatedNode) // subscribe('files:folder:deleted', pathsStore.onDeletedNode) // subscribe('files:folder:moved', pathsStore.onMovedNode) - pathsStore.initialized = true + pathsStore._initialized = true } return pathsStore diff --git a/apps/files/src/store/userconfig.ts b/apps/files/src/store/userconfig.ts index f771de7cc5c..05d63c95424 100644 --- a/apps/files/src/store/userconfig.ts +++ b/apps/files/src/store/userconfig.ts @@ -63,11 +63,11 @@ export const useUserConfigStore = () => { const userConfigStore = store() // Make sure we only register the listeners once - if (!userConfigStore.initialized) { + if (!userConfigStore._initialized) { subscribe('files:config:updated', function({ key, value }: { key: string, value: boolean }) { userConfigStore.onUpdate(key, value) }) - userConfigStore.initialized = true + userConfigStore._initialized = true } return userConfigStore diff --git a/package-lock.json b/package-lock.json index d7b5d6620f1..4fd4e2b66ae 100644 --- a/package-lock.json +++ b/package-lock.json @@ -19,7 +19,7 @@ "@nextcloud/capabilities": "^1.0.4", "@nextcloud/dialogs": "^4.0.0-beta.2", "@nextcloud/event-bus": "^3.0.2", - "@nextcloud/files": "^3.0.0-beta.7", + "@nextcloud/files": "^3.0.0-beta.8", "@nextcloud/initial-state": "^2.0.0", "@nextcloud/l10n": "^2.1.0", "@nextcloud/logger": "^2.5.0", @@ -4134,12 +4134,13 @@ } }, "node_modules/@nextcloud/files": { - "version": "3.0.0-beta.7", - "license": "AGPL-3.0-or-later", + "version": "3.0.0-beta.8", + "resolved": "https://registry.npmjs.org/@nextcloud/files/-/files-3.0.0-beta.8.tgz", + "integrity": "sha512-qzL5lKhm913mBzu//rFnKobZ5GI8iAQ7GwVUez3Gpmso6TyEm/kdSloK2dRNWHStFotQdQRbl75KoyCyoz4cXg==", "dependencies": { "@nextcloud/auth": "^2.0.0", - "@nextcloud/l10n": "^2.0.1", - "@nextcloud/logger": "^2.1.0" + "@nextcloud/l10n": "^2.1.0", + "@nextcloud/logger": "^2.5.0" }, "engines": { "node": "^16.0.0", @@ -28346,11 +28347,13 @@ } }, "@nextcloud/files": { - "version": "3.0.0-beta.7", + "version": "3.0.0-beta.8", + "resolved": "https://registry.npmjs.org/@nextcloud/files/-/files-3.0.0-beta.8.tgz", + "integrity": "sha512-qzL5lKhm913mBzu//rFnKobZ5GI8iAQ7GwVUez3Gpmso6TyEm/kdSloK2dRNWHStFotQdQRbl75KoyCyoz4cXg==", "requires": { "@nextcloud/auth": "^2.0.0", - "@nextcloud/l10n": "^2.0.1", - "@nextcloud/logger": "^2.1.0" + "@nextcloud/l10n": "^2.1.0", + "@nextcloud/logger": "^2.5.0" } }, "@nextcloud/initial-state": { diff --git a/package.json b/package.json index 4bf864391b4..f8a89e3359e 100644 --- a/package.json +++ b/package.json @@ -44,7 +44,7 @@ "@nextcloud/capabilities": "^1.0.4", "@nextcloud/dialogs": "^4.0.0-beta.2", "@nextcloud/event-bus": "^3.0.2", - "@nextcloud/files": "^3.0.0-beta.7", + "@nextcloud/files": "^3.0.0-beta.8", "@nextcloud/initial-state": "^2.0.0", "@nextcloud/l10n": "^2.1.0", "@nextcloud/logger": "^2.5.0", |