mirror of
https://github.com/wallabag/wallabag.git
synced 2024-06-16 12:10:41 +00:00
Apply CS
This commit is contained in:
parent
d4dca8f6c9
commit
ed6ca862f5
|
@ -20,7 +20,7 @@ abstract class AbstractConsumer
|
||||||
protected $eventDispatcher;
|
protected $eventDispatcher;
|
||||||
protected $logger;
|
protected $logger;
|
||||||
|
|
||||||
public function __construct(EntityManagerInterface $em, UserRepository $userRepository, AbstractImport $import, EventDispatcherInterface $eventDispatcher, LoggerInterface $logger = null)
|
public function __construct(EntityManagerInterface $em, UserRepository $userRepository, AbstractImport $import, EventDispatcherInterface $eventDispatcher, ?LoggerInterface $logger = null)
|
||||||
{
|
{
|
||||||
$this->em = $em;
|
$this->em = $em;
|
||||||
$this->userRepository = $userRepository;
|
$this->userRepository = $userRepository;
|
||||||
|
|
|
@ -15,7 +15,7 @@ class IgnoreOriginInstanceRuleFixtures extends Fixture implements ContainerAware
|
||||||
*/
|
*/
|
||||||
private $container;
|
private $container;
|
||||||
|
|
||||||
public function setContainer(ContainerInterface $container = null)
|
public function setContainer(?ContainerInterface $container = null)
|
||||||
{
|
{
|
||||||
$this->container = $container;
|
$this->container = $container;
|
||||||
}
|
}
|
||||||
|
|
|
@ -15,7 +15,7 @@ class InternalSettingFixtures extends Fixture implements ContainerAwareInterface
|
||||||
*/
|
*/
|
||||||
private $container;
|
private $container;
|
||||||
|
|
||||||
public function setContainer(ContainerInterface $container = null)
|
public function setContainer(?ContainerInterface $container = null)
|
||||||
{
|
{
|
||||||
$this->container = $container;
|
$this->container = $container;
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,7 +18,7 @@ class SiteCredentialFixtures extends Fixture implements DependentFixtureInterfac
|
||||||
*/
|
*/
|
||||||
private $container;
|
private $container;
|
||||||
|
|
||||||
public function setContainer(ContainerInterface $container = null)
|
public function setContainer(?ContainerInterface $container = null)
|
||||||
{
|
{
|
||||||
$this->container = $container;
|
$this->container = $container;
|
||||||
}
|
}
|
||||||
|
|
|
@ -26,7 +26,7 @@ abstract class WallabagMigration extends AbstractMigration implements ContainerA
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
public function setContainer(ContainerInterface $container = null)
|
public function setContainer(?ContainerInterface $container = null)
|
||||||
{
|
{
|
||||||
$this->container = $container;
|
$this->container = $container;
|
||||||
}
|
}
|
||||||
|
|
|
@ -262,7 +262,7 @@ class Config
|
||||||
*
|
*
|
||||||
* @return Config
|
* @return Config
|
||||||
*/
|
*/
|
||||||
public function setUser(User $user = null)
|
public function setUser(?User $user = null)
|
||||||
{
|
{
|
||||||
$this->user = $user;
|
$this->user = $user;
|
||||||
|
|
||||||
|
|
|
@ -252,7 +252,7 @@ class User extends BaseUser implements EmailTwoFactorInterface, GoogleTwoFactorI
|
||||||
*
|
*
|
||||||
* @return User
|
* @return User
|
||||||
*/
|
*/
|
||||||
public function setConfig(Config $config = null)
|
public function setConfig(?Config $config = null)
|
||||||
{
|
{
|
||||||
$this->config = $config;
|
$this->config = $config;
|
||||||
|
|
||||||
|
@ -333,7 +333,7 @@ class User extends BaseUser implements EmailTwoFactorInterface, GoogleTwoFactorI
|
||||||
$this->googleAuthenticatorSecret = $googleAuthenticatorSecret;
|
$this->googleAuthenticatorSecret = $googleAuthenticatorSecret;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function setBackupCodes(array $codes = null)
|
public function setBackupCodes(?array $codes = null)
|
||||||
{
|
{
|
||||||
$this->backupCodes = $codes;
|
$this->backupCodes = $codes;
|
||||||
}
|
}
|
||||||
|
|
|
@ -22,7 +22,7 @@ class PreparePagerForEntries
|
||||||
*
|
*
|
||||||
* @return Pagerfanta
|
* @return Pagerfanta
|
||||||
*/
|
*/
|
||||||
public function prepare(AdapterInterface $adapter, User $user = null)
|
public function prepare(AdapterInterface $adapter, ?User $user = null)
|
||||||
{
|
{
|
||||||
if (null === $user) {
|
if (null === $user) {
|
||||||
$user = $this->tokenStorage->getToken() ? $this->tokenStorage->getToken()->getUser() : null;
|
$user = $this->tokenStorage->getToken() ? $this->tokenStorage->getToken()->getUser() : null;
|
||||||
|
|
|
@ -141,7 +141,7 @@ class PocketImport extends AbstractImport
|
||||||
/**
|
/**
|
||||||
* Set the Http client.
|
* Set the Http client.
|
||||||
*/
|
*/
|
||||||
public function setClient(ClientInterface $client, RequestFactoryInterface $requestFactory = null, StreamFactoryInterface $streamFactory = null)
|
public function setClient(ClientInterface $client, ?RequestFactoryInterface $requestFactory = null, ?StreamFactoryInterface $streamFactory = null)
|
||||||
{
|
{
|
||||||
$this->client = new HttpMethodsClient(new PluginClient($client, [new ErrorPlugin()]), $requestFactory ?: Psr17FactoryDiscovery::findRequestFactory(), $streamFactory ?: Psr17FactoryDiscovery::findStreamFactory());
|
$this->client = new HttpMethodsClient(new PluginClient($client, [new ErrorPlugin()]), $requestFactory ?: Psr17FactoryDiscovery::findRequestFactory(), $streamFactory ?: Psr17FactoryDiscovery::findStreamFactory());
|
||||||
}
|
}
|
||||||
|
|
|
@ -23,7 +23,7 @@ class UsernameFeedTokenConverter implements ParamConverterInterface
|
||||||
/**
|
/**
|
||||||
* @param ManagerRegistry $registry Manager registry
|
* @param ManagerRegistry $registry Manager registry
|
||||||
*/
|
*/
|
||||||
public function __construct(ManagerRegistry $registry = null)
|
public function __construct(?ManagerRegistry $registry = null)
|
||||||
{
|
{
|
||||||
$this->registry = $registry;
|
$this->registry = $registry;
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,7 +16,7 @@ class ClientRepository extends ServiceEntityRepository
|
||||||
parent::__construct($registry, Client::class);
|
parent::__construct($registry, Client::class);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function findOneBy(array $criteria, array $orderBy = null)
|
public function findOneBy(array $criteria, ?array $orderBy = null)
|
||||||
{
|
{
|
||||||
if (!empty($criteria['id'])) {
|
if (!empty($criteria['id'])) {
|
||||||
// cast client id to be an integer to avoid postgres error:
|
// cast client id to be an integer to avoid postgres error:
|
||||||
|
|
Loading…
Reference in a new issue