Skip to content

Commit

Permalink
after CR 2
Browse files Browse the repository at this point in the history
  • Loading branch information
tischsoic committed Nov 21, 2023
1 parent 1911055 commit f962ad1
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
6 changes: 2 additions & 4 deletions src/lib/REST/Output/ValueObjectVisitor/ContentTree/Node.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,9 @@ public function visit(Visitor $visitor, Generator $generator, $data)

$generator->valueElement('versionNo', $data->versionNo);

$generator->startValueElement('translations', implode(',', $data->translations));
$generator->endValueElement('translations');
$generator->valueElement('translations', implode(',', $data->translations));

$generator->startValueElement('previewableTranslations', implode(',', $data->previewableTranslations));
$generator->endValueElement('previewableTranslations');
$generator->valueElement('previewableTranslations', implode(',', $data->previewableTranslations));

$generator->startValueElement('name', $data->name);
$generator->endValueElement('name');
Expand Down
3 changes: 1 addition & 2 deletions src/lib/UI/Module/ContentTree/NodeFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -349,8 +349,7 @@ private function buildNode(
$children = [];
if ($loadChildren && $depth < $this->getSetting('tree_max_depth')) {
$searchResult = $this->findSubitems($location, $limit, $offset, $sortClause, $sortOrder);
/** @var int $totalChildrenCount */
$totalChildrenCount = $searchResult->totalCount;
$totalChildrenCount = (int) $searchResult->totalCount;

/** @var \Ibexa\Contracts\Core\Repository\Values\Content\Location $childLocation */
foreach (array_column($searchResult->searchHits, 'valueObject') as $childLocation) {
Expand Down

0 comments on commit f962ad1

Please sign in to comment.