public function preUpdate(PreUpdateEventArgs $eventArgs)
    {
        $entity = $eventArgs->getEntity();
        if ($entity instanceof CategoryInterface) {
            $this->removeParentCategoryForRootCategory($entity);
        }

        return $this;
    }
public function preUpdate(PreUpdateEventArgs $eventArgs)
    {
        $entity = $eventArgs->getEntity();
        if ($entity instanceof CategoryInterface) {
            $this->removeParentCategoryForRootCategory($entity);
        }

        return $this;
    }
public function preUpdate ( PreUpdateEventArgs $ eventArgs ) { $ entity = $ eventArgs -> getEntity ( ) ; if ( $ entity instanceof CategoryInterface ) { $ this -> removeParentCategoryForRootCategory ( $ entity ) ; } return $ this ; }
Pre update event listener.

@param PreUpdateEventArgs $eventArgs The pre update event args.

@return $this Self object
Pre update event listener .