-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Description
Describe the bug
User write stages do not trigger a "Model updated" event when the user is existing if the stage is after an email stage with "activate pending user on success".
To Reproduce
Steps to reproduce the behavior:
- Create a new enrollment flow
- Add a prompt stage to enter username email and name
- Do a user write, make sure it always creates a new user and store the user as inactive
- Add an email stage, and enable "Activate pending user on success"
- Add a prompt stage to set the password
- Do another user write, make sure it never creates a user
- Do a log in
During this process there is no Model Updated event sent in the second user write.
However, when you remove the email stage, it will trigger this event.
It also triggers the correct event in the user-write on a user settings flow for example, so it seems to be related to the activation stage.
Expected behavior
A user write should trigger a Model Updated event when modifying an existing user, as it also triggers a Model Created event when a new user is written to.
Version and Deployment (please complete the following information):
- authentik version: 2023.1.2