Skip to content

Commit

Permalink
Fixed hightlight naming
Browse files Browse the repository at this point in the history
  • Loading branch information
Radiergummi committed Apr 6, 2021
1 parent f412ddf commit d2cffd6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/Model.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
* @property-read string|null _index
* @property-read string|null _type
* @property-read float|null _score
* @property-read array|null _highlight
* @property-read array|null highlight
*
* @package Matchory\Elasticsearch
*/
Expand Down Expand Up @@ -916,7 +916,7 @@ public function getScore(): ?float
*/
public function getHighlight(): ?array
{
return $this->getResultMetadataValue('_highlight');
return $this->getResultMetadataValue('highlight');
}

/**
Expand All @@ -932,7 +932,7 @@ public function getHighlight(): ?array
*/
public function getHighlights($field = null)
{
$highlights = $this->getAttribute('_highlight');
$highlights = $this->getAttribute('highlight');

if ($field && array_key_exists($field, $highlights)) {
return $highlights[$field];
Expand Down

0 comments on commit d2cffd6

Please sign in to comment.