Skip to content

Commit

Permalink
refactor: Solve merge conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
nikcio committed Jul 28, 2023
1 parent dc655d7 commit 0bc86e5
Showing 1 changed file with 7 additions and 9 deletions.
16 changes: 7 additions & 9 deletions src/Examine.Lucene/Search/LuceneSearchExecutor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,6 @@ public ISearchResults Execute()

TopDocs topDocs;
ICollector topDocsCollector;
var facetsCollector = _facetFields.Any() ? new FacetsCollector() : null;
bool trackMaxScore = _luceneQueryOptions == null ? false : _luceneQueryOptions.TrackDocumentMaxScore;
bool trackDocScores = _luceneQueryOptions == null ? false : _luceneQueryOptions.TrackDocumentScores;

Expand Down Expand Up @@ -196,23 +195,22 @@ public ISearchResults Execute()
}
}

private static FieldDoc GetScoreDocAfter(LuceneQueryOptions luceneQueryOptions)
private static FieldDoc GetScoreDocAfter(SearchAfterOptions searchAfterOptions)
{
FieldDoc scoreDocAfter;
var searchAfter = luceneQueryOptions.SearchAfter;

object[] searchAfterSortFields = new object[0];
if (luceneQueryOptions.SearchAfter.Fields != null && luceneQueryOptions.SearchAfter.Fields.Length > 0)

if (searchAfterOptions.Fields != null && searchAfterOptions.Fields.Length > 0)
{
searchAfterSortFields = luceneQueryOptions.SearchAfter.Fields;
searchAfterSortFields = searchAfterOptions.Fields;
}
if (searchAfter.ShardIndex != null)
if (searchAfterOptions.ShardIndex != null)
{
scoreDocAfter = new FieldDoc(searchAfter.DocumentId, searchAfter.DocumentScore, searchAfterSortFields, searchAfter.ShardIndex.Value);
scoreDocAfter = new FieldDoc(searchAfterOptions.DocumentId, searchAfterOptions.DocumentScore, searchAfterSortFields, searchAfterOptions.ShardIndex.Value);
}
else
{
scoreDocAfter = new FieldDoc(searchAfter.DocumentId, searchAfter.DocumentScore, searchAfterSortFields);
scoreDocAfter = new FieldDoc(searchAfterOptions.DocumentId, searchAfterOptions.DocumentScore, searchAfterSortFields);
}

return scoreDocAfter;
Expand Down

0 comments on commit 0bc86e5

Please sign in to comment.