Skip to content

Conversation

mnocon
Copy link
Contributor

@mnocon mnocon commented Sep 22, 2025

This PR fixes the following error:

 ------ --------------------------------------------------------------------------------------------------------------------------------------------------------------- 
  Line   back_office/limitation/src/Security/Limitation/Mapper/CustomLimitationValueMapper.php                                                                          
 ------ --------------------------------------------------------------------------------------------------------------------------------------------------------------- 
  :13    Return type bool of method App\Security\Limitation\Mapper\CustomLimitationValueMapper::mapLimitationValue() is not covariant with return type array of method  
         Ibexa\AdminUi\Limitation\LimitationValueMapperInterface::mapLimitationValue().                                                                                 
 ------ -----------------------------------------------------------------------------------------

The interface is typehinted to return array, not bool as in our example:
https://github.com/ibexa/admin-ui/blob/main/src/lib/Limitation/LimitationValueMapperInterface.php#L23

Other things done:

  1. Extracted CustomController to separate file and fixed PHPStan issues (except one, which I've put into the baseline).
    The last commit contains changes coming from Rector - added the interface introduced in IBX-10170: Introduced AccessCheckController contract user#111
  2. Ibexified the examples - changed occuranges of ez to ibexa

Notes:

  1. It's working!
Screenshot 2025-09-22 at 18 28 45 Screenshot 2025-09-22 at 18 27 40 2) The Notification errors reported by PHPStan are fixed in https://github.com//pull/2911 (on 4.6 first), I will merge them to 5.0 and remove the baseline changes once that PR is approved.

Copy link

Preview of modified files

Preview of modified Markdown:

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.

1 participant