summaryrefslogtreecommitdiffstats
path: root/apps/files/js
diff options
context:
space:
mode:
authorBjoern Schiessle <schiessle@owncloud.com>2014-08-08 16:11:07 +0200
committerBjoern Schiessle <schiessle@owncloud.com>2014-08-11 12:03:08 +0200
commitb3cff4beb6f3628fd914650b97f6c13285615b93 (patch)
tree6af9110ffe65e2f9ad328385866928bea11e03c1 /apps/files/js
parent6dd7d9e0af3c4c1ce62e77e0932fdebe80175d16 (diff)
downloadnextcloud-server-b3cff4beb6f3628fd914650b97f6c13285615b93.tar.gz
nextcloud-server-b3cff4beb6f3628fd914650b97f6c13285615b93.zip
add error message if user wants to rename a file which no longer exists
Diffstat (limited to 'apps/files/js')
-rw-r--r--apps/files/js/filelist.js4
1 files changed, 4 insertions, 0 deletions
diff --git a/apps/files/js/filelist.js b/apps/files/js/filelist.js
index 532ed466968..4fd57cf1279 100644
--- a/apps/files/js/filelist.js
+++ b/apps/files/js/filelist.js
@@ -1322,6 +1322,10 @@
if (!result || result.status === 'error') {
OC.dialogs.alert(result.data.message, t('core', 'Could not rename file'));
fileInfo = oldFileInfo;
+ if (result.data.code === 'sourcenotfound') {
+ self.remove(result.data.newname, {updateSummary: true});
+ return;
+ }
}
else {
fileInfo = result.data;