Initial admin user only removable through bulk action when using multisite network
|Reported by:||bananastalktome||Owned by:|
Because I have a separate login system in place, I no longer wanted the initial admin user created during setup in the system. I revoked the admin users super admin privilege, but noticed that I they still couldn't be removed using the 'Delete' link (there is a check for id not equal to 0 or 1 at line ~100 of wp-admin/network/users.php which prevents deletion, yet no error or anything is shown), however I found that through bulk actions 'Delete' option the user can be removed since no such checks are in place to prevent it.
Is there any reason for preventing the main admin user to be removed in network mode even if that user has been stripped of the super admin privilege? If so, should this bulk actions removal workaround be patched (and an error displayed when someone tries to delete that user), and if not can the ID check be removed to allow the user to be deleted?