瀏覽代碼

HBOX-297 trim in webfrontend for new files to stay compatible with windows

Christian Aigner 5 年之前
父節點
當前提交
ce37930910
共有 2 個文件被更改,包括 2 次插入2 次删除
  1. 1 1
      apps/files/js/filelist.js
  2. 1 1
      apps/files/js/newfilemenu.js

+ 1 - 1
apps/files/js/filelist.js

@@ -2600,7 +2600,7 @@
 				}
 
 				try {
-					var newName = input.val();
+					var newName = input.val().trim();
 					input.tooltip('hide');
 					form.remove();
 

+ 1 - 1
apps/files/js/newfilemenu.js

@@ -167,7 +167,7 @@
 				event.preventDefault();
 
 				if (checkInput()) {
-					var newname = $input.val();
+					var newname = $input.val().trim();
 
 					/* Find the right actionHandler that should be called.
 					 * Actions is retrieved by using `actionSpec.id` */