Support Forum

Did something change with deleting a user?

KV kvr28
kvr28
Member

When I have had spammers slip through the login process before and went to delete them there was an option to assign all their posts to another user or to delete their posts, I just went to delete a user and there were no options except for deleting the user and all their posts were left intact and they just reverted to guest status. 

Thank-you.

12 Answers

New Answer

YS Yellow Swordfish
Yellow Swordfish
Member

Odd – I have just run some tests here on the live site and on my local test sites and it seems to be working as always.I will look at the code to see if there are any conditions that might affect it but I don’t think there are.

And I suppose it is not possible you have anything else active that might have some say in what gets displayed on that WP delete user page?

KV kvr28
kvr28
Member

No and really haven’t done anything new besides updates, the only change I have made was I removed the admin plug in for SP, decided I wanted it back and re-installed it. When I get a chance I will deactivate all plug ins on my staging server and do some testing.

YS Yellow Swordfish
Yellow Swordfish
Member

Can we assume you were logged in as a full SP admin as well as WP Administrator?

KV kvr28
kvr28
Member

Yes, I am the only admin, here are my settings

admin.jpg

I disabled all the plugins and still nothing

delete.jpg

but your question on the sp/wp admin had me thinking, when we used buddypress and bbpress some reason it changed my nickname to homesteading-board, so when someone tried mentioning me in sp it would autofill with that but display as kvr on the forum, I checked the nickname settings through sp and wp and they both showed as kvr, so I poked around the database under the wp user table and sure enough it showed the homesteading-board in it so I changed it to kvr, the mentions worked fine after that, would that have anything to do with it? 

Under my wp user profile this is what shows.

bbp_keymaster, SPF Manage Options, SPF Manage Forums, SPF Manage User Groups, SPF Manage Permissions, SPF Manage Components, SPF Manage Admins, SPF Manage Users, SPF Manage Profiles, SPF Manage Toolbox, SPF Manage Plugins, SPF Manage Themes, SPF Manage Integration, SPF Manage PM, SPF Manage Polls

I don’t even have keymaster as a role anymore, I had to do this just to remove the roles from bbpress that they don’t when it is deleted.

https://codex.wordpress.org/Function_Reference/remove_role

Man I regret installing that plugin.

YS Yellow Swordfish
Yellow Swordfish
Member

That all looks fine to me. At the end of the day, as far as internal checking of capabilities and permissions goes, it is all done with your user id. And you still have the SPF capability to manage users which is required for the operation in question.

My only theory, as I said above, is that the WordPress action hook ‘delete_user_form’ is in some way compromised. But you would know if anything is active that might in any way want to manipulate that delete page.

Afraid we might need to run this one past Steve when he gets back in a few days if that is OK…

MP Mr Papa
Mr Papa
Member

no, nothing has changed here… and just did some tests and working fine…  this is SP 5.6.1? and standard wp (not multisite)?

MP Mr Papa
Mr Papa
Member

damn, I am wrong…  we did break this in 5.6.1…  🙁

in 5.6, we added some code to display a warning if you were about to delete an SP admin, but a wp bug in the form hook prevented it from working correctly…  so in 5.6.1, we commented out the warning message, but unfortunately we commented out too much…

will get it fixed up in 5.6.2 which we are tentatively planning for end of December…

MP Mr Papa
Mr Papa
Member

whoops!  yup, December would be tough… 😉