summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBart Visscher <bartv@thisnet.nl>2012-11-16 12:16:23 +0100
committerJörn Friedrich Dreyer <jfd@butonic.de>2012-11-22 11:52:05 +0100
commit1793e85a523174f66575ca4c40ceecbbe2b1c09d (patch)
tree6ce1f2c29e5840275ccfea508fa83d12f3a25d08
parent568def2b61e45d51d4506ad08723c3e2173481b4 (diff)
downloadnextcloud-server-1793e85a523174f66575ca4c40ceecbbe2b1c09d.tar.gz
nextcloud-server-1793e85a523174f66575ca4c40ceecbbe2b1c09d.zip
Also reject names with \ in the name
fixes issues #435 and #437
-rw-r--r--apps/files/js/files.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/files/js/files.js b/apps/files/js/files.js
index bb80841055b..b8972bed6b8 100644
--- a/apps/files/js/files.js
+++ b/apps/files/js/files.js
@@ -505,8 +505,8 @@ $(document).ready(function() {
$(this).append(input);
input.focus();
input.change(function(){
- if(type != 'web' && $(this).val().indexOf('/')!=-1){
- $('#notification').text(t('files','Invalid name, \'/\' is not allowed.'));
+ if(type != 'web' && ($(this).val().indexOf('/')!=-1 || $(this).val().indexOf('\\')!=-1)) {
+ $('#notification').text(t('files', 'Invalid name, \'/\' or \'\\\' is not allowed.'));
$('#notification').fadeIn();
return;
}