]> git.mxchange.org Git - friendica.git/commitdiff
Add support for source_url in Mastodon\InstanceV2
authorHypolite Petovan <hypolite@mrpetovan.com>
Wed, 4 Oct 2023 00:55:15 +0000 (20:55 -0400)
committerHypolite Petovan <hypolite@mrpetovan.com>
Wed, 4 Oct 2023 00:55:15 +0000 (20:55 -0400)
src/Module/Api/Mastodon/InstanceV2.php
src/Object/Api/Mastodon/InstanceV2.php

index 64d0955629524a51418a0fc9745fc6e58b386247..5e7511c028e0032a5da238edac851e4355157056 100644 (file)
@@ -85,6 +85,7 @@ class InstanceV2 extends BaseApi
                $domain               = $this->baseUrl->getHost();
                $title                = $this->config->get('config', 'sitename');
                $version              = '2.8.0 (compatible; Friendica ' . App::VERSION . ')';
+               $source_url           = 'https://git.friendi.ca/friendica/friendica';
                $description          = $this->config->get('config', 'info');
                $usage                = $this->buildUsageInfo();
                $thumbnail            = new InstanceEntity\Thumbnail($this->baseUrl . $this->contactHeader->getMastodonBannerPath());
@@ -98,6 +99,7 @@ class InstanceV2 extends BaseApi
                        $domain,
                        $title,
                        $version,
+                       $source_url,
                        $description,
                        $usage,
                        $thumbnail,
index ec32b944f0a2509f31e3881e457998064acafa25..89cca6daa7d33b4e7bb14dad7973e0124506919e 100644 (file)
@@ -81,6 +81,7 @@ class InstanceV2 extends BaseDataTransferObject
                string              $domain,
                string              $title,
                string              $version,
+               string              $source_url,
                string              $description,
                Usage               $usage,
                Thumbnail           $thumbnail,
@@ -94,7 +95,7 @@ class InstanceV2 extends BaseDataTransferObject
                $this->domain        = $domain;
                $this->title         = $title;
                $this->version       = $version;
-               $this->source_url    = null; //not supported yet
+               $this->source_url    = $source_url;
                $this->description   = $description;
                $this->usage         = $usage;
                $this->thumbnail     = $thumbnail;