Skip to content

Commit 0fcf33b

Browse files
MC-41854: Page builder gallery load issue
1 parent 84e590c commit 0fcf33b

File tree

1 file changed

+1
-11
lines changed
  • app/code/Magento/Cms/Block/Adminhtml/Wysiwyg/Images

1 file changed

+1
-11
lines changed

app/code/Magento/Cms/Block/Adminhtml/Wysiwyg/Images/Tree.php

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@
55
*/
66
namespace Magento\Cms\Block\Adminhtml\Wysiwyg\Images;
77

8-
use Magento\Framework\Filesystem;
9-
108
/**
119
* Directory tree renderer for Cms Wysiwyg Images
1210
*
@@ -34,33 +32,25 @@ class Tree extends \Magento\Backend\Block\Template
3432
*/
3533
private $serializer;
3634

37-
/**
38-
* @var Filesystem
39-
*/
40-
private $fileSystem;
41-
4235
/**
4336
* @param \Magento\Backend\Block\Template\Context $context
4437
* @param \Magento\Cms\Helper\Wysiwyg\Images $cmsWysiwygImages
4538
* @param \Magento\Framework\Registry $registry
4639
* @param array $data
47-
* @param Filesystem $fileSystem
4840
* @param \Magento\Framework\Serialize\Serializer\Json|null $serializer
4941
* @throws \RuntimeException
5042
*/
5143
public function __construct(
5244
\Magento\Backend\Block\Template\Context $context,
5345
\Magento\Cms\Helper\Wysiwyg\Images $cmsWysiwygImages,
5446
\Magento\Framework\Registry $registry,
55-
Filesystem $fileSystem,
5647
array $data = [],
5748
\Magento\Framework\Serialize\Serializer\Json $serializer = null
5849
) {
5950
$this->_coreRegistry = $registry;
6051
$this->_cmsWysiwygImages = $cmsWysiwygImages;
6152
$this->serializer = $serializer ?: \Magento\Framework\App\ObjectManager::getInstance()
6253
->get(\Magento\Framework\Serialize\Serializer\Json::class);
63-
$this->fileSystem = $fileSystem;
6454
parent::__construct($context, $data);
6555
}
6656

@@ -111,7 +101,7 @@ private function getFilteredNestedDirectories(string $storageRoot, string $fileN
111101
$result = [];
112102
$pathList = $this->getMediaDirectory()->read($fileName);
113103
foreach ($pathList as $directoryPath) {
114-
$directory = $this->fileSystem->getDirectoryReadByPath($storageRoot . $directoryPath);
104+
$directory = $this->_filesystem->getDirectoryReadByPath($storageRoot . $directoryPath);
115105
if (!$directory->isDirectory()) {
116106
continue;
117107
}

0 commit comments

Comments
 (0)