Skip to content

[DeadCode] Skip with elseif/else on RemoveNextSameValueConditionRector - #7809

Merged
samsonasik merged 3 commits into
mainfrom
skip-with-elseif
Jan 6, 2026
Merged

[DeadCode] Skip with elseif/else on RemoveNextSameValueConditionRector#7809
samsonasik merged 3 commits into
mainfrom
skip-with-elseif

Conversation

@samsonasik

Copy link
Copy Markdown
Member

@TomasVotruba I tested in our project and it seems cause invalid change, this PR ensure the rule only apply when there is no elseif/else in the ifs conditions.

Fixes rectorphp/rector#9585

@samsonasik

Copy link
Copy Markdown
Member Author

@TomasVotruba ready 👍 I am merging it to have faster feedback to test ;)

@samsonasik
samsonasik enabled auto-merge (squash) January 6, 2026 00:59
@samsonasik
samsonasik merged commit a72c622 into main Jan 6, 2026
58 checks passed
@samsonasik
samsonasik deleted the skip-with-elseif branch January 6, 2026 01:01
@github-actions

Copy link
Copy Markdown
Contributor

This pull request has been automatically locked because it has been closed for 150 days. Please open a new PR if you want to continue the work.

@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Aug 30, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Development

Successfully merging this pull request may close these issues.

Incorrect behavior of RemoveNextSameValueConditionRector

2 participants