This commit is contained in:
Julien Fastré 2024-04-04 22:19:56 +02:00
parent 409a571010
commit 92800f5dd0
Signed by: julienfastre
GPG Key ID: BDE2190974723FCB
20 changed files with 18 additions and 43 deletions

View File

@ -30,8 +30,7 @@ class UsersJobFilter implements FilterInterface
public function __construct(
private readonly TranslatableStringHelperInterface $translatableStringHelper,
private readonly UserJobRepositoryInterface $userJobRepository
) {
}
) {}
public function addRole(): ?string
{

View File

@ -29,8 +29,7 @@ final readonly class JobFilter implements FilterInterface
public function __construct(
private TranslatableStringHelper $translatableStringHelper,
private UserJobRepositoryInterface $userJobRepository
) {
}
) {}
public function addRole(): ?string
{

View File

@ -31,8 +31,7 @@ class ScopeFilter implements FilterInterface
protected TranslatorInterface $translator,
private readonly TranslatableStringHelper $translatableStringHelper,
private readonly ScopeRepositoryInterface $scopeRepository
) {
}
) {}
public function addRole(): ?string
{

View File

@ -18,7 +18,6 @@ use Chill\DocGeneratorBundle\Entity\DocGeneratorTemplate;
use Chill\DocGeneratorBundle\Repository\DocGeneratorTemplateRepository;
use Chill\DocGeneratorBundle\Service\Messenger\RequestGenerationMessage;
use Chill\DocStoreBundle\Entity\StoredObject;
use Chill\MainBundle\Entity\User;
use Chill\MainBundle\Form\Type\PickUserDynamicType;
use Chill\MainBundle\Pagination\PaginatorFactory;
use Chill\MainBundle\Security\ChillSecurity;
@ -36,7 +35,6 @@ use Symfony\Component\HttpKernel\Exception\BadRequestHttpException;
use Symfony\Component\HttpKernel\Exception\NotFoundHttpException;
use Symfony\Component\Messenger\MessageBusInterface;
use Symfony\Component\Routing\Annotation\Route;
use Symfony\Component\Security\Core\Security;
use Symfony\Component\Serializer\Normalizer\AbstractNormalizer;
use Symfony\Component\Validator\Constraints\NotBlank;
use Symfony\Component\Validator\Constraints\NotNull;

View File

@ -34,8 +34,7 @@ class Generator implements GeneratorInterface
private readonly ManagerRegistry $objectManagerRegistry,
private readonly LoggerInterface $logger,
private readonly StoredObjectManagerInterface $storedObjectManager
) {
}
) {}
public function generateDataDump(
DocGeneratorTemplate $template,

View File

@ -26,8 +26,7 @@ final readonly class OnAfterMessageHandledClearStoredObjectCache implements Even
public function __construct(
private StoredObjectManagerInterface $storedObjectManager,
private LoggerInterface $logger,
) {
}
) {}
public static function getSubscribedEvents()
{

View File

@ -40,8 +40,7 @@ final readonly class OnGenerationFails implements EventSubscriberInterface
private StoredObjectRepositoryInterface $storedObjectRepository,
private TranslatorInterface $translator,
private UserRepositoryInterface $userRepository
) {
}
) {}
public static function getSubscribedEvents()
{

View File

@ -46,8 +46,7 @@ class RequestGenerationHandler implements MessageHandlerInterface
private readonly MailerInterface $mailer,
private readonly TempUrlGeneratorInterface $tempUrlGenerator,
private readonly TranslatorInterface $translator,
) {
}
) {}
public function __invoke(RequestGenerationMessage $message)
{

View File

@ -17,6 +17,4 @@ use Doctrine\Persistence\ObjectRepository;
/**
* @extends ObjectRepository<StoredObject>
*/
interface StoredObjectRepositoryInterface extends ObjectRepository
{
}
interface StoredObjectRepositoryInterface extends ObjectRepository {}

View File

@ -22,7 +22,6 @@ use Chill\MainBundle\DependencyInjection\CompilerPass\ShortMessageCompilerPass;
use Chill\MainBundle\DependencyInjection\CompilerPass\TimelineCompilerClass;
use Chill\MainBundle\DependencyInjection\CompilerPass\WidgetsCompilerPass;
use Chill\MainBundle\DependencyInjection\ConfigConsistencyCompilerPass;
use Chill\MainBundle\DependencyInjection\RoleProvidersCompilerPass;
use Chill\MainBundle\Notification\NotificationHandlerInterface;
use Chill\MainBundle\Routing\LocalMenuBuilderInterface;
use Chill\MainBundle\Search\SearchApiInterface;

View File

@ -20,8 +20,7 @@ final readonly class DashboardApiController
{
public function __construct(
private NewsItemRepository $newsItemRepository,
) {
}
) {}
/**
* Get user dashboard config (not yet based on user id and still hardcoded for now).

View File

@ -25,8 +25,7 @@ class NewsItemApiController
private readonly NewsItemRepository $newsItemRepository,
private readonly SerializerInterface $serializer,
private readonly PaginatorFactory $paginatorFactory
) {
}
) {}
/**
* Get list of news items filtered on start and end date.

View File

@ -28,8 +28,7 @@ final readonly class NewsItemHistoryController
private readonly PaginatorFactory $paginatorFactory,
private readonly FilterOrderHelperFactoryInterface $filterOrderHelperFactory,
private readonly Environment $environment,
) {
}
) {}
/**
* @Route("/{_locale}/news-items/history", name="chill_main_news_items_history")

View File

@ -17,9 +17,7 @@ use Symfony\Component\Security\Core\Authorization\AuthorizationCheckerInterface;
class AdminNewsMenuBuilder implements LocalMenuBuilderInterface
{
public function __construct(private readonly AuthorizationCheckerInterface $authorizationChecker)
{
}
public function __construct(private readonly AuthorizationCheckerInterface $authorizationChecker) {}
public function buildMenu($menuId, MenuItem $menu, array $parameters)
{

View File

@ -13,7 +13,6 @@ namespace Chill\MainBundle\Security;
class RoleProvider
{
/**
* an array where keys are the role, and value is the title
* for the given role.
@ -27,9 +26,7 @@ class RoleProvider
* @var iterable<ProvideRoleInterface>
*/
private iterable $providers
)
{
}
) {}
public function getRoles(): array
{

View File

@ -24,8 +24,7 @@ final readonly class AccompanyingPeriodWorkWithEvaluationBetweenDatesFilter impl
{
public function __construct(
private RollingDateConverterInterface $rollingDateConverter,
) {
}
) {}
public function buildForm(FormBuilderInterface $builder): void
{

View File

@ -31,8 +31,7 @@ class JobFilter implements FilterInterface
protected TranslatorInterface $translator,
private readonly TranslatableStringHelper $translatableStringHelper,
private readonly UserJobRepositoryInterface $userJobRepository,
) {
}
) {}
public function addRole(): ?string
{

View File

@ -31,8 +31,7 @@ class ScopeFilter implements FilterInterface
protected TranslatorInterface $translator,
private readonly TranslatableStringHelper $translatableStringHelper,
private readonly ScopeRepositoryInterface $scopeRepository
) {
}
) {}
public function addRole(): ?string
{

View File

@ -88,8 +88,7 @@ final readonly class ListAccompanyingPeriodHelper
private UserHelper $userHelper,
private LabelPersonHelper $labelPersonHelper,
private CenterRepository $centerRepository
) {
}
) {}
public function getQueryKeys($data)
{

View File

@ -84,8 +84,7 @@ final readonly class ListPersonHelper
* @var iterable<CustomizeListPersonHelperInterface>
*/
private iterable $customPersonHelpers,
) {
}
) {}
/**
* Those keys are the "direct" keys, which are created when we decide to use to list all the keys.