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
fix(common): prevent duplicate URL change notifications #37404
fix(common): prevent duplicate URL change notifications #37404
Conversation
ac26acf
to
526aaae
Compare
Does it make sense to add an |
It looks like it won't be necessary to teardown the subscription manually, as the source is an |
c2d172d
to
4f0215d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 Thanks for this fix! Only some small nits in the comments
4f0215d
to
3fd0a17
Compare
Good to go. I'll open another PR after merge to:
in these files. |
Prevent duplicate notifications from being emitted when multiple URL change listeners are registered using Location#onUrlChange.
3fd0a17
to
d6ff176
Compare
I think you have to remove the |
Prevent duplicate notifications from being emitted when multiple URL change listeners are registered using Location#onUrlChange. PR Close #37404
Prevent duplicate notifications from being emitted when multiple URL change listeners are registered using Location#onUrlChange. PR Close angular#37404
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
Prevent duplicate notifications from being emitted when multiple URL change listeners are registered using Location#onUrlChange. PR Close angular#37404
Prevent duplicate notifications from being emitted when multiple URL change listeners are registered using
Location#onUrlChange
.PR Checklist
Please check if your PR fulfills the following requirements:
PR Type
What kind of change does this PR introduce?
What is the current behavior?
When two URL change listeners are registered, the first one will receive duplicate URL change notifications.
Issue Number: N/A
What is the new behavior?
When two URL change listeners are registered, both of them will only receive a single notification when the URL changes.
Does this PR introduce a breaking change?
Other information
Cc @aaronfrost
Location#onUrlChange
is only used by NgUpgrade's$location
shim for AngularJS.