fix phpcs

Signed-off-by: Luka Trovic <luka@nextcloud.com>
This commit is contained in:
Luka Trovic
2024-09-26 17:12:20 +02:00
parent 2a7c5b9c9c
commit 439c2b422e
44 changed files with 67 additions and 65 deletions

View File

@@ -76,7 +76,7 @@ class AssignmentService {
ChangeHelper $changeHelper,
IEventDispatcher $eventDispatcher,
AssignmentServiceValidator $assignmentServiceValidator,
$userId
$userId,
) {
$this->assignmentServiceValidator = $assignmentServiceValidator;
$this->permissionService = $permissionService;

View File

@@ -58,7 +58,7 @@ class AttachmentService {
$userId,
IL10N $l10n,
ActivityManager $activityManager,
AttachmentServiceValidator $attachmentServiceValidator
AttachmentServiceValidator $attachmentServiceValidator,
) {
$this->attachmentMapper = $attachmentMapper;
$this->cardMapper = $cardMapper;

View File

@@ -89,7 +89,7 @@ class BoardService {
IDBConnection $connection,
BoardServiceValidator $boardServiceValidator,
SessionMapper $sessionMapper,
?string $userId
?string $userId,
) {
$this->boardMapper = $boardMapper;
$this->stackMapper = $stackMapper;

View File

@@ -77,7 +77,7 @@ class CardService {
LoggerInterface $logger,
IRequest $request,
CardServiceValidator $cardServiceValidator,
?string $userId
?string $userId,
) {
$this->cardMapper = $cardMapper;
$this->stackMapper = $stackMapper;
@@ -356,11 +356,11 @@ class CardService {
$card = $this->cardMapper->update($card);
$oldBoardId = $this->stackMapper->findBoardId($changes->getBefore()->getStackId());
$boardId = $this->cardMapper->findBoardId($card->getId());
if($boardId !== $oldBoardId) {
if ($boardId !== $oldBoardId) {
$stack = $this->stackMapper->find($card->getStackId());
$board = $this->boardService->find($this->cardMapper->findBoardId($card->getId()));
$boardLabels = $board->getLabels() ?? [];
foreach($card->getLabels() as $cardLabel) {
foreach ($card->getLabels() as $cardLabel) {
$this->removeLabel($card->getId(), $cardLabel->getId());
$label = $this->labelMapper->find($cardLabel->getId());
$filteredLabels = array_values(array_filter($boardLabels, fn ($item) => $item->getTitle() === $label->getTitle()));

View File

@@ -29,7 +29,7 @@ class ConfigService {
public function __construct(
IConfig $config,
IGroupManager $groupManager
IGroupManager $groupManager,
) {
$this->groupManager = $groupManager;
$this->config = $config;

View File

@@ -27,7 +27,7 @@ class DefaultBoardService {
BoardService $boardService,
StackService $stackService,
CardService $cardService,
IConfig $config
IConfig $config,
) {
$this->boardService = $boardService;
$this->stackService = $stackService;

View File

@@ -33,7 +33,7 @@ class FileService implements IAttachmentService {
private IRootFolder $rootFolder,
private IConfig $config,
private AttachmentMapper $attachmentMapper,
private IMimeTypeDetector $mimeTypeDetector
private IMimeTypeDetector $mimeTypeDetector,
) {
}

View File

@@ -55,7 +55,7 @@ class FilesAppService implements IAttachmentService, ICustomAttachmentService {
CardMapper $cardMapper,
LoggerInterface $logger,
IDBConnection $connection,
?string $userId
?string $userId,
) {
$this->request = $request;
$this->l10n = $l10n;

View File

@@ -39,7 +39,7 @@ class FullTextSearchService {
private $cardMapper;
public function __construct(
BoardMapper $boardMapper, StackMapper $stackMapper, CardMapper $cardMapper
BoardMapper $boardMapper, StackMapper $stackMapper, CardMapper $cardMapper,
) {
$this->boardMapper = $boardMapper;
$this->stackMapper = $stackMapper;

View File

@@ -70,7 +70,7 @@ class BoardImportService {
private CardMapper $cardMapper,
private ICommentsManager $commentsManager,
private IEventDispatcher $eventDispatcher,
private LoggerInterface $logger
private LoggerInterface $logger,
) {
$this->board = new Board();
$this->disableCommentsEvents();
@@ -364,7 +364,7 @@ class BoardImportService {
$this->getImportSystem()->updateCardAssignment($cardId, (string)$assignment->getId(), $assignment);
$this->addOutput('Assignment ' . $assignment->getParticipant() . ' added');
} catch (NotFoundException $e) {
$this->addError('No origin or mapping found for card "' . $cardId . '" and ' . $assignment->getTypeString() .' assignment "' . $assignment->getParticipant(), $e);
$this->addError('No origin or mapping found for card "' . $cardId . '" and ' . $assignment->getTypeString() . ' assignment "' . $assignment->getParticipant(), $e);
}
}
}

View File

@@ -31,7 +31,7 @@ class TrelloApiService extends TrelloJsonService {
IURLGenerator $urlGenerator,
IL10N $l10n,
LoggerInterface $logger,
IClientService $httpClientService
IClientService $httpClientService,
) {
parent::__construct($userManager, $urlGenerator, $l10n);
$this->logger = $logger;

View File

@@ -37,7 +37,7 @@ class TrelloJsonService extends ABoardImportService {
public function __construct(
IUserManager $userManager,
IURLGenerator $urlGenerator,
IL10N $l10n
IL10N $l10n,
) {
$this->userManager = $userManager;
$this->urlGenerator = $urlGenerator;

View File

@@ -32,7 +32,7 @@ class LabelService {
PermissionService $permissionService,
BoardService $boardService,
ChangeHelper $changeHelper,
LabelServiceValidator $labelServiceValidator
LabelServiceValidator $labelServiceValidator,
) {
$this->labelMapper = $labelMapper;
$this->permissionService = $permissionService;

View File

@@ -36,7 +36,7 @@ class OverviewService {
AssignmentMapper $assignedUsersMapper,
IUserManager $userManager,
ICommentsManager $commentsManager,
AttachmentService $attachmentService
AttachmentService $attachmentService,
) {
$this->cardService = $cardService;
$this->boardMapper = $boardMapper;

View File

@@ -40,7 +40,7 @@ class PermissionService {
private IGroupManager $groupManager,
private IManager $shareManager,
private IConfig $config,
private ?string $userId
private ?string $userId,
) {
$this->boardCache = new CappedMemoryCache();
$this->permissionCache = new CappedMemoryCache();

View File

@@ -46,7 +46,7 @@ class SearchService {
FilterStringParser $filterStringParser,
IUserManager $userManager,
IL10N $l10n,
IURLGenerator $urlGenerator
IURLGenerator $urlGenerator,
) {
$this->boardService = $boardService;
$this->cardMapper = $cardMapper;

View File

@@ -33,7 +33,7 @@ class SessionService {
ISecureRandom $secureRandom,
ITimeFactory $timeFactory,
$userId,
IEventDispatcher $eventDispatcher
IEventDispatcher $eventDispatcher,
) {
$this->sessionMapper = $sessionMapper;
$this->secureRandom = $secureRandom;

View File

@@ -56,7 +56,7 @@ class StackService {
ChangeHelper $changeHelper,
LoggerInterface $logger,
IEventDispatcher $eventDispatcher,
StackServiceValidator $stackServiceValidator
StackServiceValidator $stackServiceValidator,
) {
$this->stackMapper = $stackMapper;
$this->boardMapper = $boardMapper;