protected function onSuccess()
    {
        $redirectionUrl = "";

        // First check if the model has a target for redirection in mind.
        if (isset($this->model->redirectUrl)) {
            $redirectionUrl = $this->model->redirectUrl;
        }

        if (!$redirectionUrl){
            // Finally fallback to the Leave's default success URL:
            $redirectionUrl = $this->getDefaultSuccessUrl();
        }

        if (!$redirectionUrl){
            $redirectionUrl = "/";
        } else {
            // Check any supplied redirection URL is on the same host
            if (!$this->isRedirectionUrlValid($redirectionUrl)){
                $redirectionUrl = "/";
            }
        }

        throw new ForceResponseException(new RedirectResponse($redirectionUrl));
    }