DEV Community

Discussion on: Wordpress hooks

Collapse
 
mike_hasarms profile image
Mike Healy

This is probably not the main issue, but are you missing a comma between $data and $course_id in the arguments for the learndash_course_completed callback?

Does $data contain the user_id?
If so can you just call memberpress_membership_account_prep() from within the callback and pass in the user_id?

(You may also want to set default values for $feed and $entry since you don't appear to be using them)