public function postPersist(LifecycleEventArgs $args)
    {
        if ($args->getObject() instanceof CommitInterface) {
            $this->dispatcher->dispatch(NewCommitEvent::NAME, new NewCommitEvent($args->getObject()));
        } elseif ($args->getObject() instanceof BranchInterface) {
            $this->dispatcher->dispatch(NewBranchEvent::NAME, new NewBranchEvent($args->getObject()));
        }
    }