Username change logging even if it failed

This isn’t any serious bug as the username still does not change, however it is a little inconvenient for moderators when viewing action logs for a specific user and they see a username change but it hasn’t actually been changed.

  1. Go to /u/[username]/preferences/username.
  2. Attempt to change the username to something that is already taken.
  3. Press the ‘change’ box when it allows you to.
    • This was a bit hard for me, I will assume this will have different outputs and timings in different environments.

Despite the username not changing, it still logs in admin/logs/staff_action_logs as the username being successfully changed:

Just thought I would report it :smiley:

Thanks.

3 Likes

This seems like a bug @techAPJ?

4 Likes

Fixed in:

https://github.com/discourse/discourse/commit/a2b1789c3e3590e354edc0b0c14886955d0d2388

Thanks for reporting this issue @Zeemah :+1:

4 Likes