WordPress.org

Make WordPress Core

Opened 3 months ago

Last modified 3 months ago

#42249 new defect (bug)

"Add Existing Users" -Form on Multisite still shows up after remove Capabilities to see it

Reported by: tqmtqm89 Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version: 4.8.2
Component: Networks and Sites Keywords: reporter-feedback
Focuses: multisite Cc:

Description

Hey there,
i got a Multisite where it should be possible for Administrators (not Super-Admins) to add new Users to their subdomain. But i'd liked to disable the option to add existing users.

So i customized the capabilities for my plan and it seems i have found a bug cause it just worked half the way.

From before changing the capabilities the state was:
https://i.imgur.com/KKXaUgQ.png

After change of capabilities just the headline was removed (i highlighted it in the screenshot above)
https://i.imgur.com/m9cEY0p.png

So what i wanted to create was something like
https://i.imgur.com/hZxjsoA.png

So i moved deep into Wordpress-Core and found the possible bug and fixed it so far for me:
https://i.imgur.com/lKXVkzZ.png

i added the if clause around the form that check the $do_both on line 326 + 377 on the wp-admin/user-new.php.

At the moment in line 314 is it checked but only hide / show the headline of add existing users but have no influence to the form.

Greetings from Paderborn

Change History (1)

#1 @swissspidy
3 months ago

  • Keywords reporter-feedback added

Hey there,

Welcome to Trac!

This sounds like a duplicate of #37836. Can you please try WordPress 4.9 Beta 2 to see if the bug is resolved? Thanks!

Note: See TracTickets for help on using tickets.