@@ 152-162 (lines=11) @@ | ||
149 | * |
|
150 | * @throws \Doctrine\DBAL\DBALException |
|
151 | */ |
|
152 | private function getNodeTranslationMap() |
|
153 | { |
|
154 | if (\is_null($this->nodeTranslationMap)) { |
|
155 | $sql = 'SELECT id, url, lang FROM kuma_node_translations'; |
|
156 | $stmt = $this->em->getConnection()->prepare($sql); |
|
157 | $stmt->execute(); |
|
158 | $this->nodeTranslationMap = $stmt->fetchAll(); |
|
159 | } |
|
160 | ||
161 | return $this->nodeTranslationMap; |
|
162 | } |
|
163 | ||
164 | /** |
|
165 | * Get a map of all media items. Only called once for caching. |
|
@@ 171-181 (lines=11) @@ | ||
168 | * |
|
169 | * @throws \Doctrine\DBAL\DBALException |
|
170 | */ |
|
171 | private function getMediaMap() |
|
172 | { |
|
173 | if (\is_null($this->mediaMap)) { |
|
174 | $sql = 'SELECT id, url FROM kuma_media'; |
|
175 | $stmt = $this->em->getConnection()->prepare($sql); |
|
176 | $stmt->execute(); |
|
177 | $this->mediaMap = $stmt->fetchAll(); |
|
178 | } |
|
179 | ||
180 | return $this->mediaMap; |
|
181 | } |
|
182 | } |
|
183 |