[PR #1392] [MERGED] Replace dots with something else on user create and edit screens #5811

Closed
opened 2026-02-05 10:17:42 +03:00 by OVERLORD · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/BookStackApp/BookStack/pull/1392
Author: @cnfw
Created: 4/15/2019
Status: Merged
Merged: 4/20/2019
Merged by: @ssddanbrown

Base: masterHead: fix/dot-in-role-names


📝 Commits (1)

  • 29f17fd Replace dots with something else on user create and edit screens

📊 Changes

1 file changed (+2 additions, -2 deletions)

View changed files

📝 resources/views/form/role-checkboxes.blade.php (+2 -2)

📄 Description

Fix for #1325
Dot notation handling in laravel means it was looking for the existence of a value in the wrong place.
Eg, if the role name was a.role.name it would look in roles['a']['role']['name'] instead of roles['a.role.name']

I couldn't find anywhere where the name of the role is used in setting roles (they are set with IDs), so changing the dots in the form elements name attribute to something else seems to have fixed this without any unintended side effects.

Could be an issue if someone had a role called a.role and a second role called aDOTrole, but I can't see this being the case for too many users.

Edit: I should note that the display name of the role isn't changed, so it will still appear in the form with dots.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/BookStackApp/BookStack/pull/1392 **Author:** [@cnfw](https://github.com/cnfw) **Created:** 4/15/2019 **Status:** ✅ Merged **Merged:** 4/20/2019 **Merged by:** [@ssddanbrown](https://github.com/ssddanbrown) **Base:** `master` ← **Head:** `fix/dot-in-role-names` --- ### 📝 Commits (1) - [`29f17fd`](https://github.com/BookStackApp/BookStack/commit/29f17fd1543e90ec12e828e4c1cef7c11d1e2d62) Replace dots with something else on user create and edit screens ### 📊 Changes **1 file changed** (+2 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `resources/views/form/role-checkboxes.blade.php` (+2 -2) </details> ### 📄 Description Fix for #1325 Dot notation handling in laravel means it was looking for the existence of a value in the wrong place. Eg, if the role name was `a.role.name` it would look in `roles['a']['role']['name']` instead of `roles['a.role.name']` I couldn't find anywhere where the name of the role is used in setting roles (they are set with IDs), so changing the dots in the form elements name attribute to something else seems to have fixed this without any unintended side effects. Could be an issue if someone had a role called `a.role` and a second role called `aDOTrole`, but I can't see this being the case for too many users. Edit: I should note that the display name of the role isn't changed, so it will still appear in the form with dots. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
OVERLORD added the pull-request label 2026-02-05 10:17:42 +03:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/BookStack#5811