File tree Expand file tree Collapse file tree 1 file changed +8
-11
lines changed Expand file tree Collapse file tree 1 file changed +8
-11
lines changed Original file line number Diff line number Diff line change @@ -67,20 +67,17 @@ const CollectionMenu = ({
6767
6868 const existingFolders = useExplorerStore . getState ( ) . explorer . folders ;
6969 const parentFolderId = folderId || collectionId ;
70- // console.log(parentFolderId, "parentfolderid")
7170 const isDuplicateName = existingFolders . some (
72- ( folder ) =>
73- // console.log(`folder name ${folder.name} and folder parent id ${folder.__ref.collectionId}`),
74-
71+ ( folder ) =>
7572 folder . name === val && folder . __ref . collectionId === parentFolderId
76- ) ;
73+ ) ;
7774
78- if ( isDuplicateName ) {
79- return {
80- isValid : false ,
81- message : 'A folder with the same name already exists in this location.' ,
82- } ;
83- }
75+ if ( isDuplicateName ) {
76+ return {
77+ isValid : false ,
78+ message : 'A folder with the same name already exists in this location.' ,
79+ } ;
80+ }
8481 return {
8582 isValid,
8683 message :
You can’t perform that action at this time.
0 commit comments