]> _ Git - cubist_minisearch.git/commitdiff
wip #5184 @0.25
authorVincent Vanwaelscappel <vincent@cubedesigners.com>
Tue, 29 Mar 2022 12:38:31 +0000 (14:38 +0200)
committerVincent Vanwaelscappel <vincent@cubedesigners.com>
Tue, 29 Mar 2022 12:38:31 +0000 (14:38 +0200)
src/Document.php

index 3352154dd66659b66e927a9d64c6541dfe4e6350..d4bec6265ec8979053e689ca1d445fa9ee0ca7f7 100644 (file)
@@ -22,7 +22,7 @@ class Document
     /**
      * @var string
      */
-    protected $displayedTitle='';
+    protected $displayedTitle = '';
 
     /**
      * @var string
@@ -168,7 +168,7 @@ class Document
      */
     public function getDisplayedTitle(): string
     {
-        return $this->displayedTitle?:$this->getTitle();
+        return $this->displayedTitle ?: $this->getTitle();
     }
 
     /**
@@ -192,7 +192,16 @@ class Document
      */
     public function getIndividualDocData()
     {
-        return ['id' => $this->getId(), 'type' => $this->getType(), 'thumb' => $this->getThumb(), 'title' => $this->getTitle(), 'url' => $this->getUrl(), 'text' => $this->getText(), 'keywords' => $this->getKeywords(),'displayedTitle'=>$this->getDisplayedTitle()];
+        return [
+            'id' => $this->getId(),
+            'type' => $this->getType(),
+            'thumb' => $this->getThumb(),
+            'title' => $this->getTitle(),
+            'url' => $this->getUrl(),
+            'text' => $this->getText(),
+            'keywords' => $this->getKeywords(),
+            'displayedTitle' => $this->getDisplayedTitle()
+        ];
     }
 
 }
\ No newline at end of file