Hooks

Actions

HookArgumentsFires
lh_shadow_taxonomies_object_shadowed$object_id, $type, $term_id, $taxonomyWhen a new shadow term is created for a user or BuddyPress group. Not fired for post types.
lh_shadow_taxonomies_object_unshadowed$object_id, $type, $term_id, $taxonomyJust before a user’s or group’s shadow term is deleted, so the term is still valid. Not fired for post types.
lh_shadow_taxonomies_term_assigned$object_id, $term_id, $taxonomy, $shadowed_id, $type, $tagged_by, $tagged_atWhen a shadow term is newly set on an object (from set_object_terms), and again for existing assignments during cron reconciliation, with $tagged_by 0 and $tagged_at empty. $tagged_at is a UTC MySQL datetime.
lh_shadow_taxonomies_term_removed$object_id, $term_id, $taxonomy, $shadowed_id, $typeWhen a shadow term is removed from an object.
lh_shadow_taxonomies_process, lh_shadow_taxonomies_initialnoneCron events (daily and one-off at activation) that run the backfill and reconciliation passes.

Filters

HookDefault and argumentsPurpose
lh_shadow_taxonomies_init_plugintrueReturn false to stop the plugin registering any hooks, without deactivating it. Evaluated on plugins_loaded.
lh_shadow_taxonomies_return_object_whitelistarray( 'user', 'bp_group', 'post' )Object types the lookup helpers accept; anything else is treated as post.
lh_shadow_taxonomies_active_post_statusesarray( 'publish' )Post statuses that get a shadow term, on save and in the backfill.
lh_shadow_taxonomies_get_blacklisted_ids_by_taxonomyarray(), $taxonomy, $object_typeObject IDs never to shadow in that taxonomy. Honoured by the backfill for all types and by maybe_shadow_user() for users; saving a post or group does not check it.
lh_shadow_taxonomies_return_object_backfill_number50, $taxonomy, $object_typeObjects backfilled per taxonomy per cron run.
lh_shadow_taxonomies_return_plugin_debugging_statusfalseWith WP_DEBUG on, return true to log term insert and update failures to the error log.