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

Clean Processor::runJob() and runScheduledJob() #109

Open
kyriog opened this issue Feb 18, 2019 · 0 comments
Open

Clean Processor::runJob() and runScheduledJob() #109

kyriog opened this issue Feb 18, 2019 · 0 comments

Comments

@kyriog
Copy link
Contributor

kyriog commented Feb 18, 2019

The \EthanYehuda\CronjobManager\Helper\Processor::runJob() method has 99% the same code of Processor::runScheduledJob().

The only difference between these two methods is when the schedule object is saved:
runJob() directly call the save() method of the schedule object itself (which is deprecated according to Magento 2 best practices) whereas runScheduledJob() runs the save() method from the object getResource().

I think runJob() should be deleted if possible, or at least being updated as deprecated and pointing to runScheduledJob() method.

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

No branches or pull requests

1 participant