Found Bug in Cron Job email Notifications Option
-
Hi, after some research i found that BP Better Messages option “Replace Standard BuddyPress Email Notifications” have some problem in a particular circumstance.
if an user try to register with default wp option or with Buddypress form, activate the account but not login in website, the result the email for new messages are not send with option “Replace Standard BuddyPress Email Notifications”.
After some research i have found this is caused by a user meta-field “last_activity” that are updated when user login.
this is the example of a query that made buddypress when log-in:
INSERT INTO 'wp_usermeta' ('user_id', 'meta_key', 'meta_value') VALUES (11, 'last_activity', '2020-09-28 10:58:47')
this field it appears to be read by your plugin in the function
notifications_sender
in notifications.php page.In particular in this position of query
WHERE {$wpdb->base_prefix}usermeta.meta_key = 'last_activity'
this blocks the sending of email notifications if a user has registered but has not yet logged in for the first time, it should therefore be fixed by also allowing notifications to be sent when the user has not yet logged in.
I consider it a Bug because if you use the default function of buddypress this problem does not occur.
In my case it is an important problem because the user is automatically registered after a contact request through a form and when I go to respond to his request via chat he does not receive the message email.
- The topic ‘Found Bug in Cron Job email Notifications Option’ is closed to new replies.