mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 01:56:46 +00:00
refactor(core): Add telemetry for RBAC roles (#7969)
Add telemetry for RBAC roles, see [requirements](https://linear.app/n8n/issue/PAY-1067/add-telemetry-events-for-adding-and-assigning-admin-users#comment-184619fe).
This commit is contained in:
@@ -391,6 +391,13 @@ export class UsersController {
|
||||
|
||||
await this.userService.update(targetUser.id, { globalRole: roleToSet });
|
||||
|
||||
void this.internalHooks.onUserRoleChange({
|
||||
user: req.user,
|
||||
target_user_id: targetUser.id,
|
||||
target_user_new_role: [newRole.scope, newRole.name].join(' '),
|
||||
public_api: false,
|
||||
});
|
||||
|
||||
return { success: true };
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user