Skip to content

node.active incorrectly returns true for headings #86

@brinkofblink

Description

@brinkofblink

Hi there,

We recently started seeing a bug where node.active is returning true for Heading nodes when viewing the homepage.
Is this a bug or is there something I've missed?

Thanks!

We're using v5.1.4 on Craft Pro 5.8.13.2 with PHP 8.3.14.

I've attached a screenshot of the navigation, and here's a stripped-back version of the macro I'm using:

{% macro renderNode(node) %}
	{% import _self as macros %}
	<li class="top-level">
		<a href="{{ node.url }}" class="{% if node.active %}active{% endif %}">
			{{ node.name }}
		</a>
	</li>
{% endmacro %}
Image

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions