Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEATURE] Include facets from all associated metadata sections for fulltext pages #1441

Merged
merged 5 commits into from
Feb 1, 2025
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
remove redundant collection_faceting
michaelkubina-subhh committed Jan 28, 2025
commit 2ebab1f496da20bb23d74b5e4995b63345303ea2
8 changes: 1 addition & 7 deletions Classes/Common/Indexer.php
Original file line number Diff line number Diff line change
@@ -455,13 +455,7 @@
if (is_array($doc->metadataArray[$doc->toplevelId])) {
self::addFaceting($doc, $solrDoc, $physicalUnit);
}
// Add collection information to physical sub-elements if applicable.
if (
in_array('collection', self::$fields['facets'])
&& !empty($doc->metadataArray[$doc->toplevelId]['collection'])
) {
$solrDoc->setField('collection_faceting', $doc->metadataArray[$doc->toplevelId]['collection']);
}

try {
$updateQuery->addDocument($solrDoc);
self::$solr->service->update($updateQuery);
@@ -553,7 +547,7 @@
*
* @return void
*/
private static function addFaceting($doc, &$solrDoc, $physicalUnit): void

Check notice on line 550 in Classes/Common/Indexer.php

Codacy Production / Codacy Static Code Analysis

Classes/Common/Indexer.php#L550

Function's nesting level (8) exceeds 5; consider refactoring the function
{
// this variable holds all possible facet-values for the index names
$facets = [];