Skip to content

Commit 533f743

Browse files
authored
Merge pull request #35 from adammeyer/master
Article Keywords support
2 parents 66f6664 + d3e6c0d commit 533f743

1 file changed

Lines changed: 22 additions & 0 deletions

File tree

src/HelpScoutDocs/Models/Article.php

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,11 @@ class Article extends ArticleRef
2222
*/
2323
private ?array $related = null;
2424

25+
/**
26+
* @var null|array|string[]
27+
*/
28+
private ?array $keywords = null;
29+
2530
public function __construct(?stdClass $data = null)
2631
{
2732
if ($data) {
@@ -31,6 +36,7 @@ public function __construct(?stdClass $data = null)
3136
$this->code = $data->code ?? null;
3237
$this->categories = $data->categories ?? null;
3338
$this->related = $data->related ?? null;
39+
$this->keywords = $data->keywords ?? null;
3440
}
3541
}
3642

@@ -85,4 +91,20 @@ public function getText(): ?string
8591
{
8692
return $this->text;
8793
}
94+
95+
/**
96+
* @param array|string[] $keywords
97+
*/
98+
public function setKeywords(?array $keywords): void
99+
{
100+
$this->keywords = $keywords;
101+
}
102+
103+
/**
104+
* @return array|string[]|null
105+
*/
106+
public function getKeywords(): ?array
107+
{
108+
return $this->keywords;
109+
}
88110
}

0 commit comments

Comments
 (0)