Fix isFolderEmpty function in userObject
parent
e949c2a6f7
commit
4a93d1829a
|
@ -109,7 +109,9 @@ define([
|
|||
};
|
||||
exp.isFolderEmpty = function (element) {
|
||||
if (!isFolder(element)) { return false; }
|
||||
return Object.keys(element).length === 0;
|
||||
if (Object.keys(element).length === 0) { return true; }
|
||||
if (Object.keys(element).length === 1 && isFolderData(element[Object.keys(element)[0]])) { return true; }
|
||||
return false;
|
||||
};
|
||||
|
||||
exp.hasSubfolder = function (element, trashRoot) {
|
||||
|
|
Loading…
Reference in New Issue