Multiple license breaks role assignment

Created on 3 January 2024, 11 months ago

Problem/Motivation

When you have more than one license active for an user (with granted date of the second one after the expre date of the first), when the first expires, the role is removed even when the second license become granted. The license role is disabled and checked in user edit, but not really assigned. The role is not present in "people" page.

Steps to reproduce

- Create two active licenses for the same user, one granted for example for one day, starting from now, and the other with granted date one day after the expire date of the first license.
- The license role is assigned to user
- Wait until the first license expires
- The license role is correctly removed from user
- Wait until second license is granted
- Check that the role SEEMS to be re-assigned if you go to user/edit page (the license role is grey and checked), but the role is not really assigned (you can check it in people view, or programmatically doing a USER::hasRole).

Proposed resolution

Adopt a more consistent way to assign or remove roles to user.

🐛 Bug report
Status

Active

Version

3.0

Component

Code

Created by

🇮🇹Italy sepa_cleversoft

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

Comments & Activities

Production build 0.71.5 2024