Skip to content

fix(migrations): Prevent removal of templates referenced with preceding whitespace characters#64855

Merged
atscott merged 1 commit intoangular:mainfrom
lukasmatta:fix-control-flow-migration-2
Nov 4, 2025
Merged

fix(migrations): Prevent removal of templates referenced with preceding whitespace characters#64855
atscott merged 1 commit intoangular:mainfrom
lukasmatta:fix-control-flow-migration-2

Conversation

@lukasmatta
Copy link
Contributor

In #64745, a control flow migration fix was introduced to handle cases where templates are referenced with a trailing semicolon. However, I missed a case where templates are referenced with preceding whitespace characters — these are still incorrectly removed during the migration.

This PR should fix this.

Fixes #64854

…ng whitespace characters

In angular#64745, a fix was introduced for templates referenced with a trailing semicolon. However, templates are still incorrectly removed when there are whitespace characters before the template name.

This commit updates the control flow migration logic to ensure templates referenced with preceding whitespace are not removed.

Fixes angular#64854
@pullapprove pullapprove bot requested a review from devversion November 2, 2025 21:30
@angular-robot angular-robot bot added the area: migrations Issues related to `ng update`/`ng generate` migrations label Nov 2, 2025
@ngbot ngbot bot added this to the Backlog milestone Nov 2, 2025
@JeanMeche JeanMeche removed the request for review from devversion November 3, 2025 11:34
@JeanMeche JeanMeche added action: merge The PR is ready for merge by the caretaker target: patch This PR is targeted for the next patch release labels Nov 4, 2025
@atscott atscott merged commit 5b210e9 into angular:main Nov 4, 2025
23 checks passed
@atscott
Copy link
Contributor

atscott commented Nov 4, 2025

This PR was merged into the repository. The changes were merged into the following branches:

@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Dec 5, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

action: merge The PR is ready for merge by the caretaker area: migrations Issues related to `ng update`/`ng generate` migrations target: patch This PR is targeted for the next patch release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Control flow migration wrongly removes ng-template when it is referenced with preceding whitespace characters

3 participants