public function aroundReindex(
        \Magento\Catalog\Model\Category $subject,
        callable $proceed
    ) {
        $proceed();

        if ($subject->getLevel() > 1) {
            $categoryIndexer = $this->indexerRegistry->get(\Smile\ElasticsuiteCatalog\Model\Category\Indexer\Fulltext::INDEXER_ID);
            if (!$categoryIndexer->isScheduled()) {
                $categoryIndexer->reindexRow($subject->getId());
            }
        }

        return;
    }
public function aroundReindex(
        \Magento\Catalog\Model\Category $subject,
        callable $proceed
    ) {
        $proceed();

        if ($subject->getLevel() > 1) {
            $categoryIndexer = $this->indexerRegistry->get(\Smile\ElasticsuiteCatalog\Model\Category\Indexer\Fulltext::INDEXER_ID);
            if (!$categoryIndexer->isScheduled()) {
                $categoryIndexer->reindexRow($subject->getId());
            }
        }

        return;
    }
public function aroundReindex ( \ Magento \ Catalog \ Model \ Category $ subject , callable $ proceed ) { $ proceed ( ) ; if ( $ subject -> getLevel ( ) > 1 ) { $ categoryIndexer = $ this -> indexerRegistry -> get ( \ Smile \ ElasticsuiteCatalog \ Model \ Category \ Indexer \ Fulltext :: INDEXER_ID ) ; if ( ! $ categoryIndexer -> isScheduled ( ) ) { $ categoryIndexer -> reindexRow ( $ subject -> getId ( ) ) ; } } return ; }
Reindex category's data after into search engine after reindexing the category

@param \Magento\Catalog\Model\Category $subject The category being reindexed
@param callable                        $proceed The parent function we are plugged on
: Magento\Catalog\Model\Category::reindex()

@return \Magento\Catalog\Model\Category
Reindex category s data after into search engine after reindexing the category