diff --git a/src/Taxonomy.php b/src/Taxonomy.php index 48ccd56..935aa1c 100644 --- a/src/Taxonomy.php +++ b/src/Taxonomy.php @@ -72,7 +72,7 @@ public function getVocabularyByNameAsArray($name) { $vocabulary = $this->vocabulary->where('name', $name)->first(); if (!is_null($vocabulary)) { - return $vocabulary->terms->lists('name', 'id')->toArray(); + return $vocabulary->terms->pluck('name', 'id')->toArray(); } return [];