U4-2117 - AncestorsOrSelf(nodeTypeAlias) vs AncestorOrSelf(nodeTypeAlias) inconsistent behaviour

Created by Dirk De Grave 16 Apr 2013, 08:20:08 Updated by Sebastiaan Janssen 25 Apr 2013, 12:45:32

See http://our.umbraco.org/forum/core/general/40163-AncestorsOrSelf(nodeTypeAlias)-vs-AncestorOrSelf(nodeTypeAlias)?p=0#comment146718 for details.

Both extension method react differently.

AncestorOrSelf(IPublishedContent this, string alias) performs a check on all nodes AncestorsOrSelf(IPublishedContent this, string alias) does not perform check on 'this' node.

Same goes for DynamicNode extension methods.

Stephen has a fix available

Comments

Stephan 16 Apr 2013, 13:31:26

Work in progress. I need to understand why, in some cases, dynamicNode.Parent == dynamicNode. Makes no sense.


Stephan 16 Apr 2013, 14:44:04

Pushed c81d8337a77a to 6.1 - should fix. Will see if it's possible to backport to 4.x and 6.0 easily.


Stephan 16 Apr 2013, 14:59:12

Pushed changesets to 4.x and 6.0 too. Should be fixed. Dirk?


Dirk De Grave 16 Apr 2013, 16:13:48

Currently don't have a v4 latest site available to check fix (still needs upgrading from v4.11.4>v4.11.6, but will do when I have. Keeping you posted!


Priority: Normal

Type: Bug

State: Fixed

Assignee: Stephan

Difficulty: Normal

Category:

Backwards Compatible: True

Fix Submitted:

Affected versions: 6.1.0, 4.11.4, 4.11.5, 4.11.6, 6.0.3

Due in version: 6.0.4, 4.11.7

Sprint:

Story Points:

Cycle: