Skip to content

Commit 8ca6c5a

Browse files
removed loadedPages
1 parent 912374c commit 8ca6c5a

File tree

1 file changed

+4
-14
lines changed

1 file changed

+4
-14
lines changed

app/code/Magento/Cms/Model/Page/DataProvider.php

Lines changed: 4 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -52,11 +52,6 @@ class DataProvider extends ModifierPoolDataProvider
5252
*/
5353
private $customLayoutManager;
5454

55-
/**
56-
* @var null|array
57-
*/
58-
private $loadedPages;
59-
6055
/**
6156
* @var LoggerInterface
6257
*/
@@ -111,7 +106,7 @@ public function __construct(
111106
* @param array $meta
112107
* @return array
113108
*/
114-
public function prepareMeta(array $meta): array
109+
public function prepareMeta(array $meta)
115110
{
116111
return $meta;
117112
}
@@ -121,7 +116,7 @@ public function prepareMeta(array $meta): array
121116
*
122117
* @return array
123118
*/
124-
public function getData(): array
119+
public function getData()
125120
{
126121
if (isset($this->loadedData)) {
127122
return $this->loadedData;
@@ -173,18 +168,13 @@ private function getCurrentPage(): Page
173168
throw new LocalizedException(__('Page ID must be given'));
174169
}
175170

176-
if (isset($this->loadedPages[$pageId])) {
177-
return $this->loadedPages[$pageId];
178-
}
179-
180-
$this->loadedPages[$pageId] = $this->pageRepository->getById($pageId);
181-
return $this->loadedPages[$pageId];
171+
return $this->pageRepository->getById($pageId);
182172
}
183173

184174
/**
185175
* @inheritDoc
186176
*/
187-
public function getMeta(): array
177+
public function getMeta()
188178
{
189179
$meta = parent::getMeta();
190180

0 commit comments

Comments
 (0)