Skip to content

[BUGFIX] Prevent Duplicates in toctree and menu #504

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

Merged
merged 1 commit into from
Aug 10, 2023

Conversation

linawolf
Copy link
Contributor

A page that has already been explicitely added to a toctree does not get added by the glob directive once more. As having multiple occurences of the same page within one toctree or menu does not make sense in general, I applied array_unique to the menu_items of one level of the toctree or menu.

@wouterj, @greg0ire is this behaviour also wanted in the doctrine and symfony docs?

@linawolf linawolf force-pushed the feature-glob-ignores-duplicates branch from 97df268 to 7a23ea4 Compare July 23, 2023 06:35
@greg0ire
Copy link
Contributor

AFAIK that's not something Doctrine would care about: it does not look like we use globs at all.

A page that has already been explicitely added to a toctree does not get added by the glob directive once more. As having multiple occurences of the same page within one toctree or menu does not make sense in general, I applied array_unique to the menu_items of one level of the toctree or menu.
@jaapio jaapio force-pushed the feature-glob-ignores-duplicates branch from 7a23ea4 to e10e781 Compare August 10, 2023 20:50
@jaapio jaapio enabled auto-merge August 10, 2023 20:50
@jaapio jaapio merged commit 72613f3 into phpDocumentor:main Aug 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants