Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

[fix] #15331 Guard against no parent #15367

Closed
wants to merge 1 commit into from
Closed

[fix] #15331 Guard against no parent #15367

wants to merge 1 commit into from

Conversation

adamreisnz
Copy link

See issue #15331

This patch silently ignores the after operation if the element does not have a parent node, following the implementation in jQuery.

@gkalpak
Copy link
Member

gkalpak commented Nov 5, 2016

Thx @adambuczynski! Could you add a test and make sure the commit message follows the guidelines.

@adamreisnz
Copy link
Author

@gkalpak sorry I don't have the time to do this now, I'm going on leave for 4 weeks 🌴 .

It's a trivial fix, maybe someone else can pick up the task to make a test for it, or just merge without test (as there was no test around this functionality to begin with).

gkalpak added a commit to gkalpak/angular.js that referenced this pull request Dec 8, 2016
Previously, the element was always assumed to have a parent and an error was
thrown when that was not the case.
This commit makes jqLite consistent with jQuery, which silently ignores a call
on elements that do not have a parent.

Fixes angular#15331
Closes angular#15367
@gkalpak
Copy link
Member

gkalpak commented Dec 8, 2016

Np, @adamreisnz. I'll take care of it. Have fun 🏂

gkalpak added a commit that referenced this pull request Dec 8, 2016
Previously, the element was always assumed to have a parent and an error was
thrown when that was not the case.
This commit makes jqLite consistent with jQuery, which silently ignores a call
on elements that do not have a parent.

Fixes #15331
Closes #15367

Closes #15475
@gkalpak gkalpak closed this in a9e9146 Dec 8, 2016
gkalpak added a commit that referenced this pull request Dec 9, 2016
Previously, the element was always assumed to have a parent and an error was
thrown when that was not the case.
This commit makes jqLite consistent with jQuery, which silently ignores a call
on elements that do not have a parent.

Fixes #15331
Closes #15367

Closes #15475
ellimist pushed a commit to ellimist/angular.js that referenced this pull request Mar 15, 2017
Previously, the element was always assumed to have a parent and an error was
thrown when that was not the case.
This commit makes jqLite consistent with jQuery, which silently ignores a call
on elements that do not have a parent.

Fixes angular#15331
Closes angular#15367

Closes angular#15475
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants