Fix
This commit is contained in:
parent
91e25ad3c0
commit
ae66154be2
2 changed files with 10 additions and 8 deletions
|
@ -21,15 +21,17 @@ class discord
|
|||
return $this->json->content;
|
||||
}
|
||||
|
||||
if(!empty($this->json->embeds->title))
|
||||
$this->readable .= PHP_EOL;
|
||||
|
||||
if(!empty($this->json->embeds[0]->title))
|
||||
{
|
||||
$this->readable .= $this->json->embeds->title . PHP_EOL;
|
||||
$this->readable .= $this->json->embeds[0]->title . PHP_EOL;
|
||||
}
|
||||
|
||||
if(!empty($this->json->embeds->description))
|
||||
if(!empty($this->json->embeds[0]->description))
|
||||
{
|
||||
$this->readable .= preg_replace("/(?:__|[*#])|\[(.*?)\]\(.*?\)/"," ",$this->json->embeds->description) . PHP_EOL;
|
||||
$this->readable .= $this->json->embeds->url;
|
||||
$this->readable .= preg_replace("/(?:__|[*#])|\[(.*?)\]\(.*?\)/"," ",$this->json->embeds[0]->description) . PHP_EOL;
|
||||
$this->readable .= $this->json->embeds[0]->url;
|
||||
}
|
||||
|
||||
return $this->readable;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue