We are running a site with Buddyboss platform where we are using Hivepress for personal ads on the site. We are also using Memberpress in order to sell VIP memberships although people can use the site as free members as well.
But now we have found we have a conflict between Hivepress and Memberpress where some users are getting a fatal error when they try to become VIP members.
The users that get the errors are users that has a personal ad on the site. But not all. The thing is that if the user update their personal ad then they will no longer get the fatal error when purchasing a VIP membership.
I have debugged the issue and it turns out that the user has an invalid taxonomy somehow. I can’t see any difference in the database between a user with the issue and a user without the issue. But apparently there is something that causes the taxonomy to be interpreted as invalid in one case and not in the other.
In the file /hivepress/includes/models/class-model.php I have added
error_log('FILLVALUES: '.print_r($values,true));
in the function
final public function fill( $values )
And this is what I get on a user that got the issue:
FILLVALUES: Array
(
[name] => user72alias
[slug] => user72alias
[description] =>
[status] => publish
[verified] =>
[registered_date] => 2022-10-09 14:28:19
[user] => 22713
[categories] => WP_Error Object
(
[errors] => Array
(
[invalid_taxonomy] => Array
(
[0] => Ogiltig taxonomi.
)
)
[error_data] => Array
(
)
[additional_data:protected] => Array
(
)
)
[image] =>
[snippet] =>
)
What can be wrong? When I look in the database the taxonomy looks alright
SELECT * FROM wp_term_relationships tr, wp_term_taxonomy tt WHERE tr.term_taxonomy_id = tt.term_taxonomy_id AND tr.object_id = [IdOfTheListingPost]
And the result of the above sql is the same after the user update the listing which make it work again.
I must be missing something.