Files
breadcrumb-the-shire/lib/Service/Auth/AuthExternalIdentityGateway.php
2026-02-23 12:58:19 +01:00

28 lines
847 B
PHP

<?php
namespace MintyPHP\Service\Auth;
use MintyPHP\Repository\User\UserExternalIdentityRepository;
class AuthExternalIdentityGateway
{
public function __construct(private readonly UserExternalIdentityRepository $userExternalIdentityRepository)
{
}
public function findByProviderTidOid(string $provider, string $tid, string $oid): ?array
{
return $this->userExternalIdentityRepository->findByProviderTidOid($provider, $tid, $oid);
}
public function findByProviderIssuerSubject(string $provider, string $issuer, string $subject): ?array
{
return $this->userExternalIdentityRepository->findByProviderIssuerSubject($provider, $issuer, $subject);
}
public function createLink(array $data): bool
{
return (bool) $this->userExternalIdentityRepository->createLink($data);
}
}