Notification emails of new users not being sent with SSO


I have our forum set to where the staff must approve all new user accounts, but the notification emails of new users are not being sent. When we first set this up, it worked fine. Now the admin no longer receives emails letting us know a new user is awaiting approval. I think the problem is that the new users aren’t being sent to “Pending”, but I don’t know why. I have to go to users -> new to find the ones that haven’t been approved. I’m also not receiving notifications of new users within Discourse.

Using WP 4.9.4 running WPLMS
WP-Discourse v1.5.8
BuddyPress v2.9.3


Thinking about it further, I think the problem is that the activation from wordpress isn’t carrying over to Discourse. If they aren’t activated in Discourse, they’re not sent to “pending”.


Anyone know what could be causing the verification in Wordpress not to carry over to Discourse?

(Simon Cossar) #4

This is correct. They end up in the New users list. They are also never sent the activation email, so they don’t get added to the Pending users list until an admin activates their account.

I’m not sure if the Discourse ‘must approve users’ setting is intended to be used with SSO. It would be more straightforward to handle user approval on the SSO Provider end, since it’s the SSO Provider that is responsible for authentication.

The WP Discourse plugin marks all email addresses as unverified until they respond to the WordPress new_user_notification email. It does this so that unverified email addresses aren’t used to create active accounts on Discourse. If you are using the BuddyPress sign up form, then you will be creating users on WordPress with unverified email addresses. Is there anything in your signup process that verifies that a user has control over the email address they use to signup with? If there is, there are ways to hook into the WP Discourse plugin to mark the email address as verified.

(Jay Dee) #5

Thank you for replying!
The theme we are using does use BuddyPress. The users are sent an “Activate your account” email, and need to activate their account before they can do anything.
We use the SSO Provider option and users are only created on the discourse forum if they indicate they want in (by following a link to the forum page). When they do that they are already activated in Wordpress.

I think you are saying that somehow the BuddyPress activation is not being carried over to the Discourse settings for the user in Wordpress.
I’m guessing that we can use the bp_core_activated_user hook to fix this. If this is the right path, is there a function we can hook into to make sure Discourse knows the user has been activated?