private function handlePrePersist()
    {
        if (null !== $this->preFunction) {
            \call_user_func($this->preFunction, $this->environment, $this->model, $this->originalModel);
        }

        $this->dispatcher->dispatch(
            PrePersistModelEvent::NAME,
            new PrePersistModelEvent($this->environment, $this->model, $this->originalModel)
        );
    }