File tree Expand file tree Collapse file tree 1 file changed +2
-3
lines changed
app/code/Magento/Cms/Block/Adminhtml/Wysiwyg/Images Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -76,8 +76,7 @@ public function getTreeJson()
7676 'path ' => substr ($ item ->getFilename (), strlen ($ storageRoot )),
7777 'cls ' => 'folder ' ,
7878 ];
79- $ nestedDirectories = $ this ->getFilteredNestedDirectories ($ storageRoot , $ item ->getFilename ());
80- $ hasNestedDirectories = count ($ nestedDirectories ) > 0 ;
79+ $ hasNestedDirectories = $ this ->hasNestedDirectories ($ storageRoot , $ item ->getFilename ());
8180
8281 // if no nested directories inside dir, add 'leaf' state so that jstree hides dropdown arrow next to dir
8382 if (!$ hasNestedDirectories ) {
@@ -96,7 +95,7 @@ public function getTreeJson()
9695 * @param string $fileName
9796 * @return array
9897 */
99- private function getFilteredNestedDirectories (string $ storageRoot , string $ fileName ): array
98+ private function hasNestedDirectories (string $ storageRoot , string $ fileName ): array
10099 {
101100 $ result = [];
102101 $ pathList = $ this ->getMediaDirectory ()->read ($ fileName );
You can’t perform that action at this time.
0 commit comments