eZ/Publish/API/Repository/Tests/SearchServiceTest.php 1 location
|
@@ 4460-4465 (lines=6) @@
|
| 4457 |
|
foreach ($result->searchHits as $hit) { |
| 4458 |
|
switch (true) { |
| 4459 |
|
case $hit->valueObject instanceof Content: |
| 4460 |
|
case $hit->valueObject instanceof Location: |
| 4461 |
|
$hit->valueObject = [ |
| 4462 |
|
'id' => $hit->valueObject->contentInfo->id, |
| 4463 |
|
'title' => $hit->valueObject->contentInfo->name, |
| 4464 |
|
]; |
| 4465 |
|
break; |
| 4466 |
|
|
| 4467 |
|
case $hit->valueObject instanceof ContentInfo: |
| 4468 |
|
$hit->valueObject = [ |
eZ/Publish/API/Repository/Tests/SearchServiceLocationTest.php 1 location
|
@@ 1144-1149 (lines=6) @@
|
| 1141 |
|
|
| 1142 |
|
foreach ($result->searchHits as $hit) { |
| 1143 |
|
switch (true) { |
| 1144 |
|
case $hit->valueObject instanceof Location: |
| 1145 |
|
$hit->valueObject = [ |
| 1146 |
|
'id' => $hit->valueObject->contentInfo->id, |
| 1147 |
|
'title' => $hit->valueObject->contentInfo->name, |
| 1148 |
|
]; |
| 1149 |
|
break; |
| 1150 |
|
|
| 1151 |
|
default: |
| 1152 |
|
throw new \RuntimeException('Unknown search result hit type: ' . get_class($hit->valueObject)); |