mirror of
https://github.com/wallabag/wallabag.git
synced 2025-01-03 13:28:41 +00:00
Apply CS
This commit is contained in:
parent
d4dca8f6c9
commit
ed6ca862f5
11 changed files with 12 additions and 12 deletions
|
@ -20,7 +20,7 @@ abstract class AbstractConsumer
|
|||
protected $eventDispatcher;
|
||||
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->userRepository = $userRepository;
|
||||
|
|
|
@ -15,7 +15,7 @@ class IgnoreOriginInstanceRuleFixtures extends Fixture implements ContainerAware
|
|||
*/
|
||||
private $container;
|
||||
|
||||
public function setContainer(ContainerInterface $container = null)
|
||||
public function setContainer(?ContainerInterface $container = null)
|
||||
{
|
||||
$this->container = $container;
|
||||
}
|
||||
|
|
|
@ -15,7 +15,7 @@ class InternalSettingFixtures extends Fixture implements ContainerAwareInterface
|
|||
*/
|
||||
private $container;
|
||||
|
||||
public function setContainer(ContainerInterface $container = null)
|
||||
public function setContainer(?ContainerInterface $container = null)
|
||||
{
|
||||
$this->container = $container;
|
||||
}
|
||||
|
|
|
@ -18,7 +18,7 @@ class SiteCredentialFixtures extends Fixture implements DependentFixtureInterfac
|
|||
*/
|
||||
private $container;
|
||||
|
||||
public function setContainer(ContainerInterface $container = null)
|
||||
public function setContainer(?ContainerInterface $container = null)
|
||||
{
|
||||
$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;
|
||||
}
|
||||
|
|
|
@ -262,7 +262,7 @@ class Config
|
|||
*
|
||||
* @return Config
|
||||
*/
|
||||
public function setUser(User $user = null)
|
||||
public function setUser(?User $user = null)
|
||||
{
|
||||
$this->user = $user;
|
||||
|
||||
|
|
|
@ -252,7 +252,7 @@ class User extends BaseUser implements EmailTwoFactorInterface, GoogleTwoFactorI
|
|||
*
|
||||
* @return User
|
||||
*/
|
||||
public function setConfig(Config $config = null)
|
||||
public function setConfig(?Config $config = null)
|
||||
{
|
||||
$this->config = $config;
|
||||
|
||||
|
@ -333,7 +333,7 @@ class User extends BaseUser implements EmailTwoFactorInterface, GoogleTwoFactorI
|
|||
$this->googleAuthenticatorSecret = $googleAuthenticatorSecret;
|
||||
}
|
||||
|
||||
public function setBackupCodes(array $codes = null)
|
||||
public function setBackupCodes(?array $codes = null)
|
||||
{
|
||||
$this->backupCodes = $codes;
|
||||
}
|
||||
|
|
|
@ -22,7 +22,7 @@ class PreparePagerForEntries
|
|||
*
|
||||
* @return Pagerfanta
|
||||
*/
|
||||
public function prepare(AdapterInterface $adapter, User $user = null)
|
||||
public function prepare(AdapterInterface $adapter, ?User $user = null)
|
||||
{
|
||||
if (null === $user) {
|
||||
$user = $this->tokenStorage->getToken() ? $this->tokenStorage->getToken()->getUser() : null;
|
||||
|
|
|
@ -141,7 +141,7 @@ class PocketImport extends AbstractImport
|
|||
/**
|
||||
* 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());
|
||||
}
|
||||
|
|
|
@ -23,7 +23,7 @@ class UsernameFeedTokenConverter implements ParamConverterInterface
|
|||
/**
|
||||
* @param ManagerRegistry $registry Manager registry
|
||||
*/
|
||||
public function __construct(ManagerRegistry $registry = null)
|
||||
public function __construct(?ManagerRegistry $registry = null)
|
||||
{
|
||||
$this->registry = $registry;
|
||||
}
|
||||
|
|
|
@ -16,7 +16,7 @@ class ClientRepository extends ServiceEntityRepository
|
|||
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'])) {
|
||||
// cast client id to be an integer to avoid postgres error:
|
||||
|
|
Loading…
Reference in a new issue