codeforamerica / classifyr

A tool for aggregating and crowd-sourcing the classification emergency call data
MIT License
0 stars 1 forks source link

Deleting a user deletes the current user #83

Closed jamesiarmes closed 2 years ago

jamesiarmes commented 2 years ago

Attempting to delete a user from the /users page deletes the current user instead.

ptrikutam commented 2 years ago

@jamesiarmes I just tried reproducing this but it worked fine for me. Could you provide steps to reproduce?

ptrikutam commented 2 years ago

For what it's worth, I was only testing locally so I'm not sure if there's something else going on with the server / database that could cause issues here.

T-Dnzt commented 2 years ago

I've run into this before and thought it was fixed. But it looks like this was introduced by https://github.com/codeforamerica/classifyr/pull/76, Devise took over the user deletion logic. It's a bit tedious to work around the Devise controllers to get what we want.

I'll add a test to reflect this issue and add a fix for it.

T-Dnzt commented 2 years ago

@jamesiarmes This should now be fixed with https://github.com/codeforamerica/classifyr/pull/92!