Hide User Register Link If Path Doesn't Exist

Created on 2 December 2024, 2 months ago

Problem/Motivation

In the site configuration, the administrator can choose to allow self registration, or by administrators only. If only administrators can register new users, the registration link shows, but generates a page not found error.

Steps to reproduce

Under account settings (/admin/config/people/accounts), in the Registration and Cancellation section, select Administrators only for Who can register accounts. Clear the cache. The Register link still appears when logged out.

Proposed resolution

Check for the existence of the path before outputting the link.

Remaining tasks

User interface changes

API changes

Data model changes

🐛 Bug report
Status

Active

Version

4.0

Component

Code

Created by

🇨🇦Canada jgreep Calgary, AB

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024