Minor corrections

This commit is contained in:
netkas 2024-10-04 12:14:32 -04:00
parent 7d9caf38b3
commit 6c2219f1ae
4 changed files with 23 additions and 4 deletions

View file

@ -33,10 +33,14 @@
/**
* @inheritDoc
*/
public static function fromArray(?array $data): BotShortDescription
public static function fromArray(?array $data): ?BotShortDescription
{
$object = new self();
if($data === null)
{
return null;
}
$object = new self();
$object->short_description = $data['short_description'];
return $object;