fix: getDirectory didn't check metadata changes
Signed-off-by: Stefan Dej <meteyou@gmail.com>
This commit is contained in:
parent
48b84f9ffd
commit
581cd2b306
@ -37,13 +37,13 @@ export const mutations: MutationTree<FileState> = {
|
|||||||
const fileIndex = path?.findIndex((element: FileStateFile) => element.filename === filename)
|
const fileIndex = path?.findIndex((element: FileStateFile) => element.filename === filename)
|
||||||
if (path && fileIndex !== -1) {
|
if (path && fileIndex !== -1) {
|
||||||
// eslint-disable-next-line
|
// eslint-disable-next-line
|
||||||
const currentFile = path[fileIndex] as any
|
const currentFile = {...path[fileIndex]} as any
|
||||||
allowedMetadata.forEach((key: string) => {
|
allowedMetadata.forEach((key: string) => {
|
||||||
if (key in payload) currentFile[key] = payload[key]
|
if (key in payload) currentFile[key] = payload[key]
|
||||||
})
|
})
|
||||||
currentFile.metadataPulled = true
|
currentFile.metadataPulled = true
|
||||||
|
|
||||||
//Vue.set(path, fileIndex, currentFile)
|
Vue.set(path, fileIndex, currentFile)
|
||||||
} else window.console.error('file not found in filetree: '+payload.filename)
|
} else window.console.error('file not found in filetree: '+payload.filename)
|
||||||
},
|
},
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user