]> source.dussan.org Git - nextcloud-server.git/commitdiff
Fix quota text not updated after copying or moving a file 32993/head
authorDaniel Calviño Sánchez <danxuliu@gmail.com>
Thu, 23 Jun 2022 11:24:58 +0000 (13:24 +0200)
committerDaniel Calviño Sánchez <danxuliu@gmail.com>
Thu, 23 Jun 2022 11:24:58 +0000 (13:24 +0200)
Note that the quota may change too when files are moved if the file is
moved, for example, to or from a folder shared by other user.

Besides the quota the storage statistics are also updated, similar to
what is done when a file is deleted.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
apps/files/js/filelist.js

index 714e66e53ed73905a847fdbb2f04ea241740501e..ac43b5456cb1241f4aa4707aa1a3de0ba4a35ebc 100644 (file)
                                                self.showFileBusyState($tr, false);
                                        });
                        };
-                       return this.reportOperationProgress(fileNames, moveFileFunction, callback);
+                       return this.reportOperationProgress(fileNames, moveFileFunction, callback).then(function() {
+                               self.updateStorageStatistics();
+                               self.updateStorageQuotas();
+                       });
                },
 
                _reflect: function (promise){
                                                }
                                        });
                        };
-                       return this.reportOperationProgress(fileNames, copyFileFunction, callback);
+                       return this.reportOperationProgress(fileNames, copyFileFunction, callback).then(function() {
+                               self.updateStorageStatistics();
+                               self.updateStorageQuotas();
+                       });
                },
 
                /**