Skip to content

IBX-12041: Applied php-cs-fixer 3.90 fixes - #3432

Merged
mnocon merged 2 commits into
5.0from
IBX-12046-php-cs-fixer-3.90-fixes-5.0
Oct 1, 2026
Merged

mnocon merged 2 commits into
5.0from
IBX-12046-php-cs-fixer-3.90-fixes-5.0

Conversation

@ViniTou

@ViniTou ViniTou commented Sep 30, 2026

Copy link
Copy Markdown
Contributor
🎫 Issue IBX-12041

Related PRs:

Description:

ibexa/code-style v2.0.1 moved php-cs-fixer to v3.90.0 (Symfony 8 support). Rules are the same, but the newer fixer applies them in more places, so the code style check started failing here. This is only the output of php-cs-fixer fix with the released code-style - no rule or code changes.

For 6.0 don't merge this branch up as is - 5.0 and 6.0 docs diverge a lot, so cherry-pick the single commit (the flagged file is identical on both branches).

For QA:

No QA. php-cs-fixer fix --dry-run with code-style v2.0.1 reports 0 files after this, php -l clean on every changed file.

Documentation:

N/A

@github-actions

Copy link
Copy Markdown

Preview of modified files: no change to preview.

@github-actions

github-actions Bot commented Sep 30, 2026 •

Copy link
Copy Markdown

Summary

Status Count
🔍 Total 750785
🔗 Unique 15085
✅ Successful 6283
⏳ Timeouts 0
🔀 Redirected 26
👻 Excluded 744465
❓ Unknown 0
🚫 Errors 37
⛔ Unsupported 0

Errors per input

Errors in site/cdp/cdp_activation/cdp_data_export/index.html

Errors in site/commerce/transactional_emails/transactional_emails/index.html

Errors in site/content_management/field_types/field_type_reference/urlfield/index.html

Errors in site/getting_started/requirements/index.html

Errors in site/ibexa_cloud/ibexa_cloud_guide/index.html

Errors in site/ibexa_products/ibexa_commerce/index.html

Errors in site/ibexa_products/ibexa_experience/index.html

Errors in site/ibexa_products/ibexa_headless/index.html

Errors in site/infrastructure_and_maintenance/cache/http_cache/reverse_proxy/index.html

Errors in site/infrastructure_and_maintenance/security/reporting_issues/index.html

Errors in site/product_catalog/quable/install_quable/index.html

Errors in site/product_catalog/quable/quable_api/index.html

Errors in site/recommendations/raptor_integration/connector_installation_configuration/index.html

Errors in site/recommendations/raptor_integration/raptor_connector/index.html

Errors in site/recommendations/raptor_integration/raptor_connector_guide/index.html

Errors in site/release_notes/cohesivo_v6.0_deprecations/index.html

Errors in site/release_notes/ez_platform_v1.10.0/index.html

Errors in site/release_notes/ez_platform_v1.11.0/index.html

Errors in site/release_notes/ez_platform_v1.12.0/index.html

Errors in site/release_notes/ez_platform_v1.13.0_lts/index.html

Errors in site/release_notes/ez_platform_v1.7.0_lts/index.html

Errors in site/release_notes/ez_platform_v1.8.0/index.html

Errors in site/release_notes/ez_platform_v1.9.0/index.html

Errors in site/release_notes/ibexa_dxp_v4.0/index.html

Errors in site/release_notes/ibexa_dxp_v4.4/index.html

Errors in site/release_notes/ibexa_dxp_v4.6/index.html

Errors in site/release_notes/ibexa_dxp_v5.0/index.html

Errors in site/resources/new_in_doc/index.html

Redirects per input

Redirects in site/cdp/cdp_activation/cdp_data_export/index.html

Redirects in site/content_management/field_types/field_type_reference/urlfield/index.html

Redirects in site/getting_started/requirements/index.html

Redirects in site/ibexa_cloud/ibexa_cloud_guide/index.html

Redirects in site/ibexa_products/ibexa_commerce/index.html

Redirects in site/ibexa_products/ibexa_experience/index.html

Redirects in site/ibexa_products/ibexa_headless/index.html

Redirects in site/infrastructure_and_maintenance/cache/http_cache/reverse_proxy/index.html

Redirects in site/infrastructure_and_maintenance/security/reporting_issues/index.html

Redirects in site/product_catalog/quable/quable_api/index.html

Redirects in site/release_notes/cohesivo_v6.0_deprecations/index.html

Redirects in site/release_notes/ez_platform_v1.13.0_lts/index.html

Redirects in site/release_notes/ez_platform_v1.7.0_lts/index.html

Redirects in site/release_notes/ibexa_dxp_v4.0/index.html

Redirects in site/release_notes/ibexa_dxp_v4.4/index.html

Redirects in site/release_notes/ibexa_dxp_v5.0/index.html

Redirects in site/resources/new_in_doc/index.html

Full Github Actions output

…issionServiceDecorator.php

Co-authored-by: Paweł Niedzielski <pawel.niedzielski@ibexa.co>
@github-actions

github-actions Bot commented Oct 1, 2026

Copy link
Copy Markdown

code_samples/ change report

Before (on target branch)After (in current PR)

code_samples/back_office/limitation/src/Security/Form/FormSubmissionServiceDecorator.php

docs/permissions/custom_policies.md@321:``` php hl_lines="19 33 40 41 44"
docs/permissions/custom_policies.md@322:[[= include_code('code_samples/back_office/limitation/src/Security/Form/FormSubmissionServiceDecorator.php') =]]
docs/permissions/custom_policies.md@323:```

001⫶<?php declare(strict_types=1);
002⫶
003⫶namespace App\Security;
004⫶
005⫶use Ibexa\Contracts\Core\Repository\ContentService;
006⫶use Ibexa\Contracts\Core\Repository\PermissionResolver;
007⫶use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo;
008⫶use Ibexa\Contracts\FormBuilder\FieldType\Model\Form;
009⫶use Ibexa\Contracts\FormBuilder\FieldType\Model\FormSubmission;
010⫶use Ibexa\Contracts\FormBuilder\FieldType\Model\FormSubmissionList;
011⫶use Ibexa\Contracts\FormBuilder\FormSubmission\FormSubmissionServiceInterface;
012⫶use Ibexa\Core\Base\Exceptions\NotFoundException;
013⫶use Ibexa\Core\Base\Exceptions\UnauthorizedException;
014⫶use Ibexa\FormBuilder\FormSubmission\Gateway\FormSubmissionGateway;
015⫶
016⫶class FormSubmissionServiceDecorator implements FormSubmissionServiceInterface
017⫶{
018⫶ public function __construct(

code_samples/back_office/limitation/src/Security/Form/FormSubmissionServiceDecorator.php

docs/permissions/custom_policies.md@321:``` php hl_lines="19 33 40 41 44"
docs/permissions/custom_policies.md@322:[[= include_code('code_samples/back_office/limitation/src/Security/Form/FormSubmissionServiceDecorator.php') =]]
docs/permissions/custom_policies.md@323:```

001⫶<?php declare(strict_types=1);
002⫶
003⫶namespace App\Security;
004⫶
005⫶use Ibexa\Contracts\Core\Repository\ContentService;
006⫶use Ibexa\Contracts\Core\Repository\PermissionResolver;
007⫶use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo;
008⫶use Ibexa\Contracts\FormBuilder\FieldType\Model\Form;
009⫶use Ibexa\Contracts\FormBuilder\FieldType\Model\FormSubmission;
010⫶use Ibexa\Contracts\FormBuilder\FieldType\Model\FormSubmissionList;
011⫶use Ibexa\Contracts\FormBuilder\FormSubmission\FormSubmissionServiceInterface;
012⫶use Ibexa\Core\Base\Exceptions\NotFoundException;
013⫶use Ibexa\Core\Base\Exceptions\UnauthorizedException;
014⫶use Ibexa\FormBuilder\FormSubmission\Gateway\FormSubmissionGateway;
015⫶
016⫶class FormSubmissionServiceDecorator implements FormSubmissionServiceInterface
017⫶{
018⫶ public function __construct(
019❇️        readonly FormSubmissionServiceInterface $innerService,
020⫶ readonly PermissionResolver $permissionResolver,
021⫶ readonly ContentService $contentService,
022⫶ readonly FormSubmissionGateway $gateway,
019❇️        private readonly FormSubmissionServiceInterface $innerService,
020⫶ private readonly PermissionResolver $permissionResolver,
021⫶ private readonly ContentService $contentService,
022⫶ private readonly FormSubmissionGateway $gateway,
023⫶    ) {
024⫶ }
025⫶
026⫶ public function create(ContentInfo $content, string $languageCode, Form $form, array $data): FormSubmission
027⫶ {
028⫶ return $this->innerService->create($content, $languageCode, $form, $data);
029⫶ }
030⫶
031⫶ public function loadById(int $id): FormSubmission
032⫶ {
033❇️ $submissions = $this->gateway->loadById($id); // First manual data fetch
034⫶
035⫶ if (empty($submissions)) {
036⫶ throw new NotFoundException('FormSubmission', $id);
037⫶ }
038⫶
039⫶ $content = $this->contentService->loadContent($submissions[0]['content_id']);
040❇️ if (!$this->permissionResolver->canUser('form', 'read_submissions', $content)) {
041❇️ throw new UnauthorizedException('form', 'read_submissions', ['contentId' => $content->getId()]); // Permission check
042⫶ }
043⫶
044❇️ return $this->innerService->loadById($id); // Second data fetch through inner service
045⫶ }
046⫶
047⫶ // The same permission check pattern is repeated in the methods below
048⫶
049⫶ public function delete(FormSubmission $submission): void
050⫶ {
051⫶ $submissionId = $submission->getId();
052⫶ $submissions = $this->gateway->loadById($submissionId);
053⫶
054⫶ if (empty($submissions)) {
055⫶ throw new NotFoundException('FormSubmission', $submissionId);
056⫶ }
057⫶
058⫶ $content = $this->contentService->loadContent($submissions[0]['content_id']);
059⫶ if (!$this->permissionResolver->canUser('form', 'read_submissions', $content)) {
060⫶ throw new UnauthorizedException('form', 'read_submissions', ['contentId' => $content->getId()]);
061⫶ }
062⫶
063⫶ $this->innerService->delete($submission);
064⫶ }
065⫶
066⫶ public function loadByContent(ContentInfo $content, ?string $languageCode = null, int $offset = 0, int $limit = 25): FormSubmissionList
067⫶ {
068⫶ if (!$this->permissionResolver->canUser('form', 'read_submissions', $content)) {
069⫶ throw new UnauthorizedException('form', 'read_submissions', ['contentId' => $content->getId()]);
070⫶ }
071⫶
072⫶ return $this->innerService->loadByContent($content, $languageCode, $offset, $limit);
073⫶ }
074⫶
075⫶ public function loadAllByContentForExport(ContentInfo $content, ?string $languageCode = null): array
076⫶ {
077⫶ if (!$this->permissionResolver->canUser('form', 'read_submissions', $content)) {
078⫶ throw new UnauthorizedException('form', 'read_submissions', ['contentId' => $content->getId()]);
079⫶ }
080⫶
081⫶ return $this->innerService->loadAllByContentForExport($content, $languageCode);
082⫶ }
083⫶
084⫶ public function loadHeaders(ContentInfo $content, ?string $languageCode = null): array
085⫶ {
086⫶ if (!$this->permissionResolver->canUser('form', 'read_submissions', $content)) {
087⫶ throw new UnauthorizedException('form', 'read_submissions', ['contentId' => $content->getId()]);
088⫶ }
089⫶
090⫶ return $this->innerService->loadHeaders($content, $languageCode);
091⫶ }
092⫶
093⫶ public function getCount(ContentInfo $content, ?string $languageCode = null): int
094⫶ {
095⫶ if (!$this->permissionResolver->canUser('form', 'read_submissions', $content)) {
096⫶ throw new UnauthorizedException('form', 'read_submissions', ['contentId' => $content->getId()]);
097⫶ }
098⫶
099⫶ return $this->innerService->getCount($content, $languageCode);
100⫶ }
101⫶}

023⫶    ) {
024⫶ }
025⫶
026⫶ public function create(ContentInfo $content, string $languageCode, Form $form, array $data): FormSubmission
027⫶ {
028⫶ return $this->innerService->create($content, $languageCode, $form, $data);
029⫶ }
030⫶
031⫶ public function loadById(int $id): FormSubmission
032⫶ {
033❇️ $submissions = $this->gateway->loadById($id); // First manual data fetch
034⫶
035⫶ if (empty($submissions)) {
036⫶ throw new NotFoundException('FormSubmission', $id);
037⫶ }
038⫶
039⫶ $content = $this->contentService->loadContent($submissions[0]['content_id']);
040❇️ if (!$this->permissionResolver->canUser('form', 'read_submissions', $content)) {
041❇️ throw new UnauthorizedException('form', 'read_submissions', ['contentId' => $content->getId()]); // Permission check
042⫶ }
043⫶
044❇️ return $this->innerService->loadById($id); // Second data fetch through inner service
045⫶ }
046⫶
047⫶ // The same permission check pattern is repeated in the methods below
048⫶
049⫶ public function delete(FormSubmission $submission): void
050⫶ {
051⫶ $submissionId = $submission->getId();
052⫶ $submissions = $this->gateway->loadById($submissionId);
053⫶
054⫶ if (empty($submissions)) {
055⫶ throw new NotFoundException('FormSubmission', $submissionId);
056⫶ }
057⫶
058⫶ $content = $this->contentService->loadContent($submissions[0]['content_id']);
059⫶ if (!$this->permissionResolver->canUser('form', 'read_submissions', $content)) {
060⫶ throw new UnauthorizedException('form', 'read_submissions', ['contentId' => $content->getId()]);
061⫶ }
062⫶
063⫶ $this->innerService->delete($submission);
064⫶ }
065⫶
066⫶ public function loadByContent(ContentInfo $content, ?string $languageCode = null, int $offset = 0, int $limit = 25): FormSubmissionList
067⫶ {
068⫶ if (!$this->permissionResolver->canUser('form', 'read_submissions', $content)) {
069⫶ throw new UnauthorizedException('form', 'read_submissions', ['contentId' => $content->getId()]);
070⫶ }
071⫶
072⫶ return $this->innerService->loadByContent($content, $languageCode, $offset, $limit);
073⫶ }
074⫶
075⫶ public function loadAllByContentForExport(ContentInfo $content, ?string $languageCode = null): array
076⫶ {
077⫶ if (!$this->permissionResolver->canUser('form', 'read_submissions', $content)) {
078⫶ throw new UnauthorizedException('form', 'read_submissions', ['contentId' => $content->getId()]);
079⫶ }
080⫶
081⫶ return $this->innerService->loadAllByContentForExport($content, $languageCode);
082⫶ }
083⫶
084⫶ public function loadHeaders(ContentInfo $content, ?string $languageCode = null): array
085⫶ {
086⫶ if (!$this->permissionResolver->canUser('form', 'read_submissions', $content)) {
087⫶ throw new UnauthorizedException('form', 'read_submissions', ['contentId' => $content->getId()]);
088⫶ }
089⫶
090⫶ return $this->innerService->loadHeaders($content, $languageCode);
091⫶ }
092⫶
093⫶ public function getCount(ContentInfo $content, ?string $languageCode = null): int
094⫶ {
095⫶ if (!$this->permissionResolver->canUser('form', 'read_submissions', $content)) {
096⫶ throw new UnauthorizedException('form', 'read_submissions', ['contentId' => $content->getId()]);
097⫶ }
098⫶
099⫶ return $this->innerService->getCount($content, $languageCode);
100⫶ }
101⫶}

Download colorized diff

@mnocon
mnocon merged commit 6566699 into 5.0 Oct 1, 2026
9 of 12 checks passed
@mnocon
mnocon deleted the IBX-12046-php-cs-fixer-3.90-fixes-5.0 branch October 1, 2026 11:33
mnocon pushed a commit that referenced this pull request Oct 1, 2026
* IBX-12046: Applied php-cs-fixer 3.90 fixes

* Update code_samples/back_office/limitation/src/Security/Form/FormSubmissionServiceDecorator.php

Co-authored-by: Paweł Niedzielski <pawel.niedzielski@ibexa.co>

---------

Co-authored-by: Paweł Niedzielski <pawel.niedzielski@ibexa.co>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants