Skip to content

Don't generate empty argument objects #26

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

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

jorrit
Copy link
Contributor

@jorrit jorrit commented Sep 6, 2021

I have a fairly large API and as such a lot of PHP files are generated by the OQM code generator.

Most of the field in my schema have no arguments, but right now the OQM generates an empty ArgumentsObject class for each object field.

This PR enhances the code generator so an ArgumentsObject is only generated when a field accepts arguments.

@jorrit
Copy link
Contributor Author

jorrit commented Sep 7, 2021

@mghoneimy I've tried this change on my code base and it removes a large amount of useless classes.

@jorrit jorrit force-pushed the noemptyargs branch 5 times, most recently from a1f9a1b to 5d8684d Compare August 23, 2024 14:18
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