mirror of
https://git.code.sf.net/p/seeddms/code
synced 2024-11-26 15:32:13 +00:00
propperly check for duplicate folder names in op/op.Ajax.php
This commit is contained in:
parent
8a217a9254
commit
8bcf76ca8c
|
@ -17,6 +17,7 @@
|
|||
- clearing cache of js files works for a large number of files
|
||||
- WebDAV returns `quota-used-bytes` and `quota-available-bytes`
|
||||
- fix settings SeedDMS attributes in WebDAV server
|
||||
- propperly check for duplicate folder names in op/op.Ajax.php
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
Changes in version 5.1.35
|
||||
|
|
|
@ -1090,10 +1090,10 @@ switch($command) {
|
|||
$name = utf8_basename($userfilename);
|
||||
|
||||
/* Check if name already exists in the folder */
|
||||
if(!$settings->_enableDuplicateDocNames) {
|
||||
if($folder->hasDocumentByName($name)) {
|
||||
if(!$settings->_enableDuplicateSubFolderNames) {
|
||||
if($folder->hasSubFolderByName($name)) {
|
||||
header('Content-Type: application/json');
|
||||
echo json_encode(array('success'=>false, 'message'=>getMLText("document_duplicate_name")));
|
||||
echo json_encode(array('success'=>false, 'message'=>getMLText("subfolder_duplicate_name")));
|
||||
exit;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user