2021-10-27 12:14:01 +09:00
|
|
|
<?php
|
|
|
|
|
2021-12-26 18:48:16 +09:00
|
|
|
declare(strict_types = 1);
|
2021-10-27 12:14:01 +09:00
|
|
|
|
2021-12-04 13:07:08 +09:00
|
|
|
// {{{ License
|
2021-10-27 12:14:01 +09:00
|
|
|
// This file is part of GNU social - https://www.gnu.org/software/social
|
|
|
|
//
|
|
|
|
// GNU social is free software: you can redistribute it and/or modify
|
|
|
|
// it under the terms of the GNU Affero General Public License as published by
|
|
|
|
// the Free Software Foundation, either version 3 of the License, or
|
|
|
|
// (at your option) any later version.
|
|
|
|
//
|
|
|
|
// GNU social is distributed in the hope that it will be useful,
|
|
|
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
// GNU Affero General Public License for more details.
|
|
|
|
//
|
|
|
|
// You should have received a copy of the GNU Affero General Public License
|
|
|
|
// along with GNU social. If not, see <http://www.gnu.org/licenses/>.
|
2021-12-04 13:07:08 +09:00
|
|
|
// }}}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* ActivityPub implementation for GNU social
|
|
|
|
*
|
|
|
|
* @package GNUsocial
|
|
|
|
* @category ActivityPub
|
2021-12-26 18:48:16 +09:00
|
|
|
*
|
2021-12-04 13:07:08 +09:00
|
|
|
* @author Diogo Peralta Cordeiro <@diogo.site>
|
|
|
|
* @copyright 2018-2019, 2021 Free Software Foundation, Inc http://www.fsf.org
|
|
|
|
* @license https://www.gnu.org/licenses/agpl.html GNU AGPL v3 or later
|
|
|
|
*/
|
2021-10-27 12:14:01 +09:00
|
|
|
|
|
|
|
namespace Plugin\ActivityPub\Util;
|
|
|
|
|
2022-03-27 23:19:09 +09:00
|
|
|
use App\Core\DB;
|
2021-10-27 12:14:01 +09:00
|
|
|
use App\Core\HTTPClient;
|
|
|
|
use App\Core\Log;
|
2022-02-25 10:05:28 +09:00
|
|
|
use App\Entity\Actor;
|
|
|
|
use App\Entity\LocalUser;
|
2022-10-20 21:23:58 +09:00
|
|
|
use App\Entity\Note;
|
2022-02-25 10:05:28 +09:00
|
|
|
use App\Util\Common;
|
2021-10-27 12:14:01 +09:00
|
|
|
use App\Util\Exception\NoSuchActorException;
|
2022-02-25 10:05:28 +09:00
|
|
|
use App\Util\Nickname;
|
2021-10-27 12:14:01 +09:00
|
|
|
use Exception;
|
2022-02-25 10:05:28 +09:00
|
|
|
use InvalidArgumentException;
|
2021-12-26 18:48:16 +09:00
|
|
|
use const JSON_UNESCAPED_SLASHES;
|
2021-10-27 12:14:01 +09:00
|
|
|
use Plugin\ActivityPub\ActivityPub;
|
|
|
|
use Plugin\ActivityPub\Entity\ActivitypubActor;
|
|
|
|
use Symfony\Contracts\HttpClient\Exception\ClientExceptionInterface;
|
|
|
|
use Symfony\Contracts\HttpClient\Exception\RedirectionExceptionInterface;
|
|
|
|
use Symfony\Contracts\HttpClient\Exception\ServerExceptionInterface;
|
|
|
|
use Symfony\Contracts\HttpClient\Exception\TransportExceptionInterface;
|
2022-10-20 21:23:58 +09:00
|
|
|
use Symfony\Contracts\HttpClient\ResponseInterface;
|
2021-10-27 12:14:01 +09:00
|
|
|
|
|
|
|
/**
|
|
|
|
* ActivityPub's own Explorer
|
|
|
|
*
|
|
|
|
* Allows to discovery new remote actors
|
|
|
|
*
|
2021-12-04 13:07:08 +09:00
|
|
|
* @copyright 2021 Free Software Foundation, Inc http://www.fsf.org
|
|
|
|
* @license https://www.gnu.org/licenses/agpl.html GNU AGPL v3 or later
|
2021-10-27 12:14:01 +09:00
|
|
|
*/
|
|
|
|
class Explorer
|
|
|
|
{
|
2022-02-25 10:05:28 +09:00
|
|
|
private array $discovered_actors = [];
|
2021-10-27 12:14:01 +09:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Shortcut function to get a single profile from its URL.
|
|
|
|
*
|
2022-10-20 21:23:58 +09:00
|
|
|
* @param bool $try_online whether to try online grabbing, defaults to true
|
|
|
|
* @param Actor $on_behalf_of AP Actor on behalf of whom any remote lookups are to be performed, defaults to null.
|
|
|
|
* If null, outgoing GET request(s) will not be http signed.
|
|
|
|
*
|
2021-10-27 12:14:01 +09:00
|
|
|
* @throws ClientExceptionInterface
|
|
|
|
* @throws NoSuchActorException
|
|
|
|
* @throws RedirectionExceptionInterface
|
|
|
|
* @throws ServerExceptionInterface
|
|
|
|
* @throws TransportExceptionInterface
|
|
|
|
*/
|
2022-10-20 21:23:58 +09:00
|
|
|
public static function getOneFromUri(string $uri, bool $try_online = true, ?Actor $on_behalf_of = null): Actor
|
2021-10-27 12:14:01 +09:00
|
|
|
{
|
2022-10-20 21:23:58 +09:00
|
|
|
$actors = (new self())->lookup($uri, $try_online, $on_behalf_of);
|
2022-02-25 10:05:28 +09:00
|
|
|
switch (\count($actors)) {
|
|
|
|
case 1:
|
|
|
|
return $actors[0];
|
|
|
|
case 0:
|
|
|
|
throw new NoSuchActorException('Invalid Actor.');
|
|
|
|
default:
|
|
|
|
throw new InvalidArgumentException('More than one actor found for this URI.');
|
2021-10-27 12:14:01 +09:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Get every profile from the given URL
|
|
|
|
* This function cleans the $this->discovered_actor_profiles array
|
|
|
|
* so that there is no erroneous data
|
|
|
|
*
|
2022-10-20 21:23:58 +09:00
|
|
|
* @param string $uri User's url
|
|
|
|
* @param bool $try_online whether to try online grabbing, defaults to true
|
|
|
|
* @param Actor $on_behalf_of AP Actor on behalf of whom the lookup is being performed, defaults to null.
|
|
|
|
* If null, outgoing GET request(s) will not be http signed.
|
2021-10-27 12:14:01 +09:00
|
|
|
*
|
|
|
|
* @throws ClientExceptionInterface
|
|
|
|
* @throws NoSuchActorException
|
|
|
|
* @throws RedirectionExceptionInterface
|
|
|
|
* @throws ServerExceptionInterface
|
|
|
|
* @throws TransportExceptionInterface
|
|
|
|
*
|
2021-12-04 13:07:08 +09:00
|
|
|
* @return array of Actor objects
|
2021-10-27 12:14:01 +09:00
|
|
|
*/
|
2022-10-20 21:23:58 +09:00
|
|
|
public function lookup(string $uri, bool $try_online = true, ?Actor $on_behalf_of = null): array
|
2021-10-27 12:14:01 +09:00
|
|
|
{
|
2022-02-25 10:05:28 +09:00
|
|
|
if (\in_array($uri, ActivityPub::PUBLIC_TO)) {
|
2021-10-27 12:14:01 +09:00
|
|
|
return [];
|
|
|
|
}
|
|
|
|
|
2022-02-25 10:05:28 +09:00
|
|
|
Log::debug('ActivityPub Explorer: Started now looking for ' . $uri);
|
|
|
|
$this->discovered_actors = [];
|
2021-10-27 12:14:01 +09:00
|
|
|
|
2022-10-20 21:23:58 +09:00
|
|
|
return $this->_lookup($uri, $try_online, $on_behalf_of);
|
2021-10-27 12:14:01 +09:00
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Get every profile from the given URL
|
|
|
|
* This is a recursive function that will accumulate the results on
|
|
|
|
* $discovered_actor_profiles array
|
|
|
|
*
|
2022-10-20 21:23:58 +09:00
|
|
|
* @param string $uri User's url
|
|
|
|
* @param bool $try_online whether to try online grabbing, defaults to true
|
|
|
|
* @param Actor $on_behalf_of Actor on behalf of whom the lookup is being performed, defaults to null.
|
|
|
|
* If null, outgoing GET request(s) will not be http signed.
|
2021-10-27 12:14:01 +09:00
|
|
|
*
|
|
|
|
* @throws ClientExceptionInterface
|
|
|
|
* @throws NoSuchActorException
|
|
|
|
* @throws RedirectionExceptionInterface
|
|
|
|
* @throws ServerExceptionInterface
|
|
|
|
* @throws TransportExceptionInterface
|
|
|
|
*
|
2022-02-25 10:05:28 +09:00
|
|
|
* @return array of Actor objects
|
2021-10-27 12:14:01 +09:00
|
|
|
*/
|
2022-10-20 21:23:58 +09:00
|
|
|
private function _lookup(string $uri, bool $try_online = true, ?Actor $on_behalf_of = null): array
|
2021-10-27 12:14:01 +09:00
|
|
|
{
|
2022-02-25 10:05:28 +09:00
|
|
|
$grab_known = $this->grabKnownActor($uri);
|
2021-10-27 12:14:01 +09:00
|
|
|
|
|
|
|
// First check if we already have it locally and, if so, return it.
|
|
|
|
// If the known fetch fails and remote grab is required: store locally and return.
|
2022-10-20 21:23:58 +09:00
|
|
|
if (!$grab_known && (!$try_online || !$this->grabRemoteActor($uri, $on_behalf_of))) {
|
2021-10-27 12:14:01 +09:00
|
|
|
throw new NoSuchActorException('Actor not found.');
|
|
|
|
}
|
|
|
|
|
2022-02-25 10:05:28 +09:00
|
|
|
return $this->discovered_actors;
|
2021-10-27 12:14:01 +09:00
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Get a known user profile from its URL and joins it on
|
|
|
|
* $this->discovered_actor_profiles
|
|
|
|
*
|
|
|
|
* @param string $uri Actor's uri
|
|
|
|
*
|
|
|
|
* @throws Exception
|
|
|
|
* @throws NoSuchActorException
|
|
|
|
*
|
|
|
|
* @return bool success state
|
|
|
|
*/
|
2022-02-25 10:05:28 +09:00
|
|
|
private function grabKnownActor(string $uri): bool
|
2021-10-27 12:14:01 +09:00
|
|
|
{
|
|
|
|
Log::debug('ActivityPub Explorer: Searching locally for ' . $uri . ' offline.');
|
|
|
|
|
2022-10-20 21:23:58 +09:00
|
|
|
if (!Common::isValidHttpUrl($uri)) {
|
|
|
|
Log::debug('ActivityPub Explorer: URI ' . $uri . ' was not a valid http url.');
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
|
|
|
// Check if uri corresponds to local actor
|
|
|
|
$resource_parts = parse_url($uri);
|
|
|
|
if ($resource_parts['host'] === Common::config('site', 'server')) {
|
|
|
|
$actor = $this::getLocalActorForPath($resource_parts['path']);
|
|
|
|
if (!\is_null($actor)) {
|
|
|
|
Log::debug('ActivityPub Explorer: Found local ActivityPub Actor for ' . $uri);
|
|
|
|
$this->discovered_actors[] = $actor;
|
|
|
|
return true;
|
|
|
|
} else {
|
|
|
|
Log::debug('ActivityPub Explorer: Unable to find a known local ActivityPub Actor for ' . $uri);
|
2022-02-25 10:05:28 +09:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2022-10-20 21:23:58 +09:00
|
|
|
// URI isn't for a local actor, try to get by URI more generally
|
2022-02-19 02:48:06 +09:00
|
|
|
$aprofile = DB::findOneBy(ActivitypubActor::class, ['uri' => $uri], return_null: true);
|
|
|
|
if (!\is_null($aprofile)) {
|
2022-02-25 10:05:28 +09:00
|
|
|
Log::debug('ActivityPub Explorer: Found a known ActivityPub Actor for ' . $uri);
|
|
|
|
$this->discovered_actors[] = $aprofile->getActor();
|
2021-10-27 12:14:01 +09:00
|
|
|
return true;
|
|
|
|
} else {
|
2022-02-25 10:05:28 +09:00
|
|
|
Log::debug('ActivityPub Explorer: Unable to find a known ActivityPub Actor for ' . $uri);
|
2021-10-27 12:14:01 +09:00
|
|
|
}
|
|
|
|
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Get a remote user(s) profile(s) from its URL and joins it on
|
|
|
|
* $this->discovered_actor_profiles
|
|
|
|
*
|
2022-10-20 21:23:58 +09:00
|
|
|
* @param string $uri User's url
|
|
|
|
* @param Actor $on_behalf_of Actor on behalf of whom http GET requests are to be made, defaults to null.
|
|
|
|
* If null, outgoing GET request(s) will not be http signed.
|
2021-10-27 12:14:01 +09:00
|
|
|
*
|
|
|
|
* @throws ClientExceptionInterface
|
|
|
|
* @throws NoSuchActorException
|
|
|
|
* @throws RedirectionExceptionInterface
|
|
|
|
* @throws ServerExceptionInterface
|
|
|
|
* @throws TransportExceptionInterface
|
|
|
|
*
|
|
|
|
* @return bool success state
|
|
|
|
*/
|
2022-10-20 21:23:58 +09:00
|
|
|
private function grabRemoteActor(string $uri, ?Actor $on_behalf_of = null): bool
|
2021-10-27 12:14:01 +09:00
|
|
|
{
|
2022-10-20 21:23:58 +09:00
|
|
|
$response = $this->get($uri, $on_behalf_of);
|
2021-12-26 18:48:16 +09:00
|
|
|
$res = json_decode($response->getContent(), true);
|
2021-10-27 12:14:01 +09:00
|
|
|
if ($response->getStatusCode() == 410) { // If it was deleted
|
|
|
|
return true; // Nothing to add.
|
|
|
|
} elseif (!HTTPClient::statusCodeIsOkay($response)) { // If it is unavailable
|
|
|
|
return false; // Try to add at another time.
|
|
|
|
}
|
2021-12-26 18:48:16 +09:00
|
|
|
if (\is_null($res)) {
|
2021-12-04 13:07:08 +09:00
|
|
|
Log::debug('ActivityPub Explorer: Invalid response returned from given Actor URL: ' . $res);
|
2021-10-27 12:14:01 +09:00
|
|
|
return true; // Nothing to add.
|
|
|
|
}
|
|
|
|
|
2021-12-04 13:07:08 +09:00
|
|
|
if ($res['type'] === 'OrderedCollection') { // It's a potential collection of actors!!!
|
2022-02-25 10:05:28 +09:00
|
|
|
Log::debug('ActivityPub Explorer: Found a collection of actors for ' . $uri);
|
2022-10-20 21:23:58 +09:00
|
|
|
$this->travelCollection($res['first'], $on_behalf_of);
|
2021-10-27 12:14:01 +09:00
|
|
|
return true;
|
|
|
|
} else {
|
2021-12-04 13:07:08 +09:00
|
|
|
try {
|
2022-02-26 23:45:38 +09:00
|
|
|
$this->discovered_actors[] = DB::wrapInTransaction(fn () => Model\Actor::fromJson(json_encode($res)))->getActor();
|
2021-12-04 13:07:08 +09:00
|
|
|
return true;
|
|
|
|
} catch (Exception $e) {
|
|
|
|
Log::debug(
|
2022-02-25 10:05:28 +09:00
|
|
|
'ActivityPub Explorer: Invalid potential remote actor while grabbing remotely: ' . $uri
|
2021-12-04 13:07:08 +09:00
|
|
|
. '. He returned the following: ' . json_encode($res, JSON_UNESCAPED_SLASHES)
|
2021-12-26 18:48:16 +09:00
|
|
|
. ' and the following exception: ' . $e->getMessage(),
|
2021-12-04 13:07:08 +09:00
|
|
|
);
|
|
|
|
return false;
|
|
|
|
}
|
2021-10-27 12:14:01 +09:00
|
|
|
}
|
|
|
|
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Allows the Explorer to transverse a collection of persons.
|
|
|
|
*
|
2022-10-20 21:23:58 +09:00
|
|
|
* @param Actor $on_behalf_of Actor on behalf of whom http GET requests are to be made, defaults to null.
|
|
|
|
* If null, outgoing GET request(s) will not be http signed.
|
|
|
|
* @param string $uri Collection's url
|
|
|
|
*
|
2021-12-04 13:07:08 +09:00
|
|
|
* @throws ClientExceptionInterface
|
2021-10-27 12:14:01 +09:00
|
|
|
* @throws NoSuchActorException
|
2021-12-04 13:07:08 +09:00
|
|
|
* @throws RedirectionExceptionInterface
|
|
|
|
* @throws ServerExceptionInterface
|
|
|
|
* @throws TransportExceptionInterface
|
2021-10-27 12:14:01 +09:00
|
|
|
*/
|
2022-10-20 21:23:58 +09:00
|
|
|
private function travelCollection(string $uri, ?Actor $on_behalf_of = null): bool
|
2021-10-27 12:14:01 +09:00
|
|
|
{
|
2022-10-20 21:23:58 +09:00
|
|
|
$response = $this->get($uri, $on_behalf_of);
|
2021-12-26 18:48:16 +09:00
|
|
|
$res = json_decode($response->getContent(), true);
|
2021-10-27 12:14:01 +09:00
|
|
|
|
|
|
|
if (!isset($res['orderedItems'])) {
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2022-02-25 10:05:28 +09:00
|
|
|
// Accumulate findings
|
|
|
|
foreach ($res['orderedItems'] as $actor_uri) {
|
2022-10-20 21:23:58 +09:00
|
|
|
$this->_lookup($actor_uri, true, $on_behalf_of);
|
2021-10-27 12:14:01 +09:00
|
|
|
}
|
2022-02-25 10:05:28 +09:00
|
|
|
|
2021-10-27 12:14:01 +09:00
|
|
|
// Go through entire collection
|
2021-12-26 18:48:16 +09:00
|
|
|
if (!\is_null($res['next'])) {
|
2022-10-20 21:23:58 +09:00
|
|
|
$this->travelCollection($res['next'], $on_behalf_of);
|
2021-10-27 12:14:01 +09:00
|
|
|
}
|
|
|
|
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
2022-10-20 21:23:58 +09:00
|
|
|
/**
|
|
|
|
* Perform an http GET request to the given uri. Will be http-signed on behalf of given Actor, if provided.
|
|
|
|
*
|
|
|
|
* @param Actor $on_behalf_of Actor on behalf of whom http GET requests are to be made, defaults to null.
|
|
|
|
* If null, outgoing GET request(s) will not be http signed.
|
|
|
|
* @param string $uri uri of remote resource, expected to return an Activity/Object of some kind.
|
|
|
|
*
|
|
|
|
* @return ResponseInterface The http response, for further processing.
|
|
|
|
*/
|
|
|
|
public static function get(string $uri, ?Actor $on_behalf_of = null): ResponseInterface
|
|
|
|
{
|
|
|
|
$headers = [];
|
|
|
|
if (!\is_null($on_behalf_of)) {
|
|
|
|
// sign the http GET request
|
|
|
|
$headers = HTTPSignature::sign($on_behalf_of, $uri, body: false, addlHeaders: [], method: 'get');
|
|
|
|
} else {
|
|
|
|
// just do a bare request
|
|
|
|
$headers = ACTIVITYPUB::HTTP_CLIENT_HEADERS;
|
|
|
|
}
|
|
|
|
|
|
|
|
return HTTPClient::get($uri, ['headers' => $headers]);
|
|
|
|
}
|
|
|
|
|
2021-10-27 12:14:01 +09:00
|
|
|
/**
|
|
|
|
* Get a remote user array from its URL (this function is only used for
|
|
|
|
* profile updating and shall not be used for anything else)
|
|
|
|
*
|
2022-10-20 21:23:58 +09:00
|
|
|
* @param string $uri User's url
|
|
|
|
* @param Actor $on_behalf_of Actor on behalf of whom http GET requests are to be made, defaults to null.
|
|
|
|
* If null, outgoing GET request(s) will not be http signed.
|
2021-10-27 12:14:01 +09:00
|
|
|
*
|
|
|
|
* @throws ClientExceptionInterface
|
2021-12-26 18:48:16 +09:00
|
|
|
* @throws Exception
|
2021-10-27 12:14:01 +09:00
|
|
|
* @throws RedirectionExceptionInterface
|
|
|
|
* @throws ServerExceptionInterface
|
|
|
|
* @throws TransportExceptionInterface
|
|
|
|
*
|
2021-12-26 18:48:16 +09:00
|
|
|
* @return null|string If it is able to fetch, false if it's gone
|
2021-10-27 12:14:01 +09:00
|
|
|
* // Exceptions when network issues or unsupported Activity format
|
|
|
|
*/
|
2022-10-20 21:23:58 +09:00
|
|
|
public static function getRemoteActorActivity(string $uri, ?Actor $on_behalf_of = null): string|null
|
2021-10-27 12:14:01 +09:00
|
|
|
{
|
2022-10-20 21:23:58 +09:00
|
|
|
$response = Explorer::get($uri, $on_behalf_of);
|
2021-10-27 12:14:01 +09:00
|
|
|
// If it was deleted
|
|
|
|
if ($response->getStatusCode() == 410) {
|
2021-12-05 12:11:08 +09:00
|
|
|
return null;
|
2021-10-27 12:14:01 +09:00
|
|
|
} elseif (!HTTPClient::statusCodeIsOkay($response)) { // If it is unavailable
|
|
|
|
throw new Exception('Non Ok Status Code for given Actor URL.');
|
|
|
|
}
|
2021-12-05 12:11:08 +09:00
|
|
|
return $response->getContent();
|
2021-10-27 12:14:01 +09:00
|
|
|
}
|
2022-10-20 21:23:58 +09:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Parse the given path and return the actor it corresponds to.
|
|
|
|
*
|
|
|
|
* @param String $path Path on *this instance*. Will be parsed with regular expressions.
|
|
|
|
* Something like `/actor/1` or `/object/note/1`.
|
|
|
|
*
|
|
|
|
* @return Actor|null The actor corresponding to/owning the given uri, null if not found.
|
|
|
|
*/
|
|
|
|
public static function getLocalActorForPath(string $path): Actor|null
|
|
|
|
{
|
|
|
|
// TODO: Use URLMatcher
|
|
|
|
|
|
|
|
// actor_view_nickname
|
|
|
|
$renick = '/\/@(' . Nickname::DISPLAY_FMT . ')\/?/';
|
|
|
|
if (preg_match_all($renick, $path, $matches, \PREG_SET_ORDER, 0) === 1) {
|
|
|
|
return DB::findOneBy(LocalUser::class, ['nickname' => $matches[0][1]])->getActor();
|
|
|
|
}
|
|
|
|
|
|
|
|
// actor_view_id
|
|
|
|
$reuri = '/\/actor\/(\d+)\/?/';
|
|
|
|
if (preg_match_all($reuri, $path, $matches, \PREG_SET_ORDER, 0) === 1) {
|
|
|
|
return Actor::getById((int) $matches[0][1]);
|
|
|
|
}
|
|
|
|
|
|
|
|
// note / page / article match
|
|
|
|
$renote = '/\/object\/(?:note|page|article)\/(\d+)\/?/';
|
|
|
|
if (preg_match_all($renote, $path, $matches, \PREG_SET_ORDER, 0) === 1) {
|
|
|
|
return Note::getById((int) $matches[0][1])->getActor();
|
|
|
|
}
|
|
|
|
|
|
|
|
return null;
|
|
|
|
}
|
2021-10-27 12:14:01 +09:00
|
|
|
}
|