Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix argument 3 of AdminMaker #6772

Merged
merged 4 commits into from
Jan 15, 2021
Merged

Conversation

franmomu
Copy link
Member

Subject

The third argument of AdminMaker could be a service name:

'%sonata.admin.configuration.default_controller%',

This PR adds a compiler pass which retrieves this parameters and check if it is a service, in that case, it replaces the argument 3 by the class name of the service definition.

I am targeting this branch, because this is BC.

Changelog

### Fixed
- Fixed using admin maker command having a default controller service.

This fixes when the third argument of AdminMaker is a service name
instead of a class. It retrieves the service name and replaces it
with the class name.
@franmomu franmomu added the patch label Jan 14, 2021
Copy link
Member

@VincentLanglet VincentLanglet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is some NEXT_MAJOR comment to add because in master the controller will be the second argument and not the third (Since it will be required I had to make this change in #6770)

@VincentLanglet VincentLanglet requested a review from a team January 15, 2021 11:34
@OskarStark OskarStark merged commit 12586a7 into sonata-project:3.x Jan 15, 2021
@franmomu franmomu deleted the fix_maker branch January 15, 2021 17:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants