mirror of
https://github.com/friendica/friendica
synced 2025-05-07 00:24:10 +02:00
Merge pull request #14745 from MrPetovan/bug/14744-mastodon-api-instance
Fix wrong default value for contact_account in Mastodon\Instance
This commit is contained in:
commit
6e264724f8
1 changed files with 19 additions and 35 deletions
|
@ -24,40 +24,24 @@ use Friendica\Object\Api\Mastodon\InstanceV2\Configuration;
|
||||||
*/
|
*/
|
||||||
class Instance extends BaseDataTransferObject
|
class Instance extends BaseDataTransferObject
|
||||||
{
|
{
|
||||||
/** @var string (URL) */
|
protected string $uri;
|
||||||
protected $uri;
|
protected string $title;
|
||||||
/** @var string */
|
protected string $short_description;
|
||||||
protected $title;
|
protected string $description;
|
||||||
/** @var string */
|
protected string $email;
|
||||||
protected $short_description;
|
protected string $version;
|
||||||
/** @var string */
|
protected array $urls;
|
||||||
protected $description;
|
protected Stats $stats;
|
||||||
/** @var string */
|
/** This is meant as a server banner, default Mastodon "thumbnail" is 1600×620px */
|
||||||
protected $email;
|
protected ?string $thumbnail = null;
|
||||||
/** @var string */
|
protected array $languages;
|
||||||
protected $version;
|
protected int $max_toot_chars;
|
||||||
/** @var array */
|
protected bool $registrations;
|
||||||
protected $urls;
|
protected bool $approval_required;
|
||||||
/** @var Stats */
|
protected bool $invites_enabled;
|
||||||
protected $stats;
|
protected Configuration $configuration;
|
||||||
/** @var string|null This is meant as a server banner, default Mastodon "thumbnail" is 1600×620px */
|
protected ?Account $contact_account = null;
|
||||||
protected $thumbnail = null;
|
protected array $rules = [];
|
||||||
/** @var array */
|
|
||||||
protected $languages;
|
|
||||||
/** @var int */
|
|
||||||
protected $max_toot_chars;
|
|
||||||
/** @var bool */
|
|
||||||
protected $registrations;
|
|
||||||
/** @var bool */
|
|
||||||
protected $approval_required;
|
|
||||||
/** @var bool */
|
|
||||||
protected $invites_enabled;
|
|
||||||
/** @var Configuration */
|
|
||||||
protected $configuration;
|
|
||||||
/** @var Account|null */
|
|
||||||
protected $contact_account = null;
|
|
||||||
/** @var array */
|
|
||||||
protected $rules = [];
|
|
||||||
|
|
||||||
public function __construct(IManageConfigValues $config, BaseURL $baseUrl, Database $database, Configuration $configuration, ?Account $contact_account, array $rules)
|
public function __construct(IManageConfigValues $config, BaseURL $baseUrl, Database $database, Configuration $configuration, ?Account $contact_account, array $rules)
|
||||||
{
|
{
|
||||||
|
@ -77,7 +61,7 @@ class Instance extends BaseDataTransferObject
|
||||||
$this->approval_required = ($register_policy === Register::APPROVE);
|
$this->approval_required = ($register_policy === Register::APPROVE);
|
||||||
$this->invites_enabled = false;
|
$this->invites_enabled = false;
|
||||||
$this->configuration = $configuration;
|
$this->configuration = $configuration;
|
||||||
$this->contact_account = $contact_account ?? [];
|
$this->contact_account = $contact_account;
|
||||||
$this->rules = $rules;
|
$this->rules = $rules;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue