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

[CodeQuality] Add DateTimeToDateTimeInterfaceRector #4791

Merged
merged 6 commits into from
Dec 5, 2020
Merged

[CodeQuality] Add DateTimeToDateTimeInterfaceRector #4791

merged 6 commits into from
Dec 5, 2020

Conversation

simivar
Copy link
Contributor

@simivar simivar commented Dec 5, 2020

Closes #4478

Co-authored-by: Tomas Votruba <tomas.vot@gmail.com>
*/
final class DateTimeToDateTimeInterfaceRector extends AbstractRector
{
private const METHODS_MAP = [
Copy link
Member

@TomasVotruba TomasVotruba Dec 5, 2020

Choose a reason for hiding this comment

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

What kind of map is this? Excluded, included or ...?
More specific naming could help

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I've renamed it to METHODS_RETURNING_CLASS_INSTANCE_MAP.

Copy link
Member

@TomasVotruba TomasVotruba left a comment

Choose a reason for hiding this comment

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

Very clean work 👍

Copy link
Member

@TomasVotruba TomasVotruba left a comment

Choose a reason for hiding this comment

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

I've left few comments. After they get resolved, it's ready to merge 👍

@TomasVotruba TomasVotruba changed the title Add DateTimeToDateTimeInterfaceRector [CodeQuality] Add DateTimeToDateTimeInterfaceRector Dec 5, 2020
@TomasVotruba
Copy link
Member

Thank you 👍

@TomasVotruba TomasVotruba merged commit 47a9a52 into rectorphp:master Dec 5, 2020
@simivar simivar deleted the fature/datetime-to-datetimeinterface-rector branch December 5, 2020 21:22
TomasVotruba added a commit that referenced this pull request Aug 14, 2023
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.

Fixer to migrate from DateTime to DateTimeInterface
2 participants