Web: Files: fixed finalizeVersionAction
This commit is contained in:
parent
a98e5d9c6a
commit
8c8bef2418
@ -598,13 +598,15 @@ class FilesActionStore {
|
|||||||
};
|
};
|
||||||
|
|
||||||
finalizeVersionAction = (id) => {
|
finalizeVersionAction = (id) => {
|
||||||
const { fetchFiles, setIsLoading } = this.filesStore;
|
const { setFile, setIsLoading } = this.filesStore;
|
||||||
|
|
||||||
setIsLoading(true);
|
setIsLoading(true);
|
||||||
|
|
||||||
return finalizeVersion(id, 0, false)
|
return finalizeVersion(id, 0, false)
|
||||||
.then(() => {
|
.then((res) => {
|
||||||
fetchFiles(this.selectedFolderStore.id, this.filesStore.filter);
|
if (res && res[0]) {
|
||||||
|
setFile(res[0]);
|
||||||
|
}
|
||||||
})
|
})
|
||||||
.finally(() => setIsLoading(false));
|
.finally(() => setIsLoading(false));
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user