"Login" link shows up for logged-in users as well

Created on 14 May 2014, about 10 years ago
Updated 26 February 2024, 4 months ago

Problem/Motivation

In D7, a manual created menu link pointing to "user/login" only showed up if I'm not already logged in.
In D8, the link shows up no matter whether I'm already logged in or not.
Guess that has something to do with the new routing system.

Steps to replicate this issue:
- Goto: /admin/structure/menu/manage/main
- Add a menu link "Login" to the path "/user/login"
- Go to the home page, , whilst logged in, you should have 2 links "Home" and "Login"

On Drupal 7 you wouldn't see this link.

Proposed resolution

Before

After

Remaining tasks

Resolve questions raised in #114 πŸ› "Login" link shows up for logged-in users as well Needs work
Is this working as designed? If not, what other places need updating.

User interface changes

Yes, login menu item will not display if one is already logged in

API changes

Data model changes

Release notes snippet

πŸ› Bug report
Status

Closed: duplicate

Version

11.0 πŸ”₯

Component
Menu systemΒ  β†’

Last updated 4 days ago

Created by

Pancho UTC+2 πŸ‡ͺπŸ‡Ί EU

Live updates comments and jobs are added and updated live.
  • Regression

    It restores functionality that was present in earlier versions.

Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.69.0 2024