mbin icon indicating copy to clipboard operation
mbin copied to clipboard

Fix user soft delete and user account restore within 30 days

Open nobodyatroot opened this issue 1 year ago • 0 comments

User soft deletes (restorability within 30 days) were not being set with the right visibility property (aka not calling the softDelete method) and therefore not being displayed in the admin panel user deletion page:

After fix: image

Users also had no way to restore their account within 30 days without contacting an admin, this PR now allows them to restore their account within 30 days by logging back into the site within the deletion window.

Added check to prevent federated users from login, should never be allowed... stops "lucky" guesses on random password generated.

I also tweaked the soft delete functions between user and magazine to be similar, but they're not exactly the same since magazine deletion is a hot mess and needs the same treatment as what @BentiGorlich did for user deletes.

nobodyatroot avatar Aug 11 '24 00:08 nobodyatroot