chg: [internal] Fetch less columns for Tag for event index

pull/7881/head
Jakub Onderka 2021-10-25 09:24:24 +02:00
parent a78722bb23
commit fc2c6c7147
1 changed files with 1 additions and 0 deletions

View File

@ -549,6 +549,7 @@ class Event extends AppModel
$tags = $this->EventTag->Tag->find('all', array(
'conditions' => array('Tag.id' => $tagsToFetch),
'recursive' => -1,
'fields' => ['id', 'name', 'colour', 'is_galaxy'], // fetch just necessary columns
'order' => false
));
$tags = array_column(array_column($tags, 'Tag'), null, 'id');