humhub / humhub

HumHub is an Open Source Enterprise Social Network. Easy to install, intuitive to use and extendable with countless freely available modules.
https://www.humhub.com
Other
6.29k stars 1.66k forks source link

Administrators can't invite new external users via email if the option for members is disabled #6893

Open hochleitner opened 6 months ago

hochleitner commented 6 months ago

This is a follow-up to https://github.com/humhub/humhub/issues/6228

What steps will reproduce the problem?

  1. Install HumHub 1.15.3
  2. As an administrator user, go to "Administration -> Settings".
  3. Disable the options "Members can invite external users by email" and "Members can invite external users by email" and save the settings (my installation is in German, but here is the screenshots). image
  4. Go back to "Overview" and select "Add new user". image
  5. On the following screen, the button for email invitation is missing. image
  6. Go back to the settings, enable both options and save. image
  7. Again, go back to "Overview" and click "Add new user". The "Invite new people" button is now here; users can be invited by entering their email addresses. image

What is the expected result?

Admin users should always be allowed to invite users by email since this setting should only affect regular members.

What do you get instead?

The button is missing when the setting is disabled. This means I have to enable the setting, which potentially allows my users to invite anyone if they notice that. This is problematic for a closed instance where the admin invites their users.

Additional info

Q A
HumHub version 1.15.3
PHP version 8.3.3 CGI/FastCGI
Operating system Debian 5.10.205-2 (2023-12-31) x86_64 GNU/Linux
WizWareTech commented 6 months ago

This would be great if it is fixed. It has been a while now and is cumbersome to have to turn the feature on just for admin to invite, then turn it back off so users can't invite. Obviously since Admin can turn on the feature, then admin should just be able to invite without having to enable it first then disable it again.