private function incrementWhileExists(Page $model, $uri, $locale, $id = null)
    {
        if (!$uri) {
            return '';
        }

        $originalUri = $uri;

        $i = 0;
        // Check if uri is unique
        while ($this->uriExists($model, $uri, $locale, $id)) {
            $i++;
            // increment uri if it exists
            $uri = $originalUri.'-'.$i;
        }

        return $uri;
    }