KEMBAR78
[Attributes] Cover slash newline in AnnotationToAttributeRector with values by TomasVotruba · Pull Request #6557 · rectorphp/rector-src · GitHub
Skip to content

Conversation

@TomasVotruba
Copy link
Member

@TomasVotruba TomasVotruba commented Dec 11, 2024

No description provided.

@TomasVotruba TomasVotruba changed the title tv behat attr [Attributes] Cover slash newline in AnnotationToAttributeRector with values Dec 11, 2024
@TomasVotruba TomasVotruba enabled auto-merge (squash) December 11, 2024 22:06
@TomasVotruba TomasVotruba merged commit 4b38333 into main Dec 11, 2024
40 of 41 checks passed
@TomasVotruba TomasVotruba deleted the tv-behat-attr branch December 11, 2024 22:06
// special case for newline
$docValue = (string) $docNode->value;
if (str_contains($docValue, '\\')) {
$docValue = Strings::replace($docValue, "#\\\\\n#", '');
Copy link
Member

Choose a reason for hiding this comment

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

"\r?\n" should be used to support windows newline

Copy link
Member

Choose a reason for hiding this comment

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

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.

2 participants