FacetWP – support for Enhanced Media Library plugin

mgibbs189

{{gist file=”test.php” lang=”php”}}
<?php

function index_attachment_terms( $object_id ) {
if ( 0 < (int) $object_id ) {
FWP()->indexer->index( $object_id );
}
}
add_action( ‘set_object_terms’, ‘index_attachment_terms’ );

{{/gist}}