Skip to content

[CodeQuality][Printer] Handle mix php+html on TernaryFalseExpressionToIfRector#3382

Merged
TomasVotruba merged 4 commits intomainfrom
patch-14
Feb 15, 2023
Merged

[CodeQuality][Printer] Handle mix php+html on TernaryFalseExpressionToIfRector#3382
TomasVotruba merged 4 commits intomainfrom
patch-14

Conversation

@samsonasik
Copy link
Copy Markdown
Member

kkmuffme and others added 4 commits February 15, 2023 18:29
# Failing Test for TernaryFalseExpressionToIfRector

Based on https://getrector.com/demo/d48f8822-9454-4055-b14c-174a6b4f2ec8

The input code makes no sense (missing echo), but is valid. Rector should not change it to invalid (fatal) code.

Possible sanity check if the change results in `?> ?>` or `<?php <?php` it shouldn't apply the change but report an error right away, to make debugging rector rules faster?
@samsonasik samsonasik changed the title [CodeQuality] Handle mix php+html on TernaryFalseExpressionToIfRector [CodeQuality][Printer] Handle mix php+html on TernaryFalseExpressionToIfRector Feb 15, 2023
@samsonasik
Copy link
Copy Markdown
Member Author

All checks have passed 🎉 @TomasVotruba it is ready for review.

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.

3 participants