fusionauth-issues
fusionauth-issues copied to clipboard
Webhook Event user.registration.update.complete not sending updated roles
Event user.registration.update.complete not sending updated roles
Description
The Webhook event user.registration.update.complete is invoked with any user role is added into the registed app. In event we are not receiving the new added role name. And on removing a role, in the webhook event data we are getting Role name which is removed.
Affects versions
1.40
Steps to reproduce
Steps to reproduce the behavior:
- Go to Webooks and enable the user.registration.update.complete event. Also enable in Tenant
- Click on User
- Click on Manage
- On Application click Edit
- Select a Role and click on save
- Observe the Event object event.original.roles
- Value will be empty array which is as expected
- Observe the Event object event.registration.roles
- Value will be empty array which is not expected, role name should appear
Expected behavior
In the event object event.registration.roles newly selected event name should come in array
Screenshots
Platform
(Please complete the following information)
- Device: Desktop
- OS: Windows
- Browser chrome + latest version [e.g. chrome, safari plus a version]
- Database [PostgresSQL] & and 12.12
Community guidelines
All issues filed in this repository must abide by the FusionAuth community guidelines.
Additional context
None
Thanks for filing @sjswami !
I have replicated this on 1.40.1.
The value in event.original.roles
is the same as the value in event.registration.roles
, when the latter should be the new role.
You can see this here: https://requestbin.com/r/en46qikwl3yl7/2FRgrfdDa6Erau1brjgReHp21Lb
To replicate:
- set up a user.registration.update.complete webhook listener.
- modify a user's role using the admin UI
- modify the user's role again
Expected: the new role shows up under registrations
. Reality: old role shows up in both places.
Internal:
- Review entire user and registration object being sent in this event. Check for custom user data, custom registration data and roles.
Any progress in fixing this bug. When we can expect to be released.
Internal:
- https://github.com/FusionAuth/fusionauth-app/pull/281