Cviebrock\EloquentSluggable\Services\SlugService::getSlugSource PHP Method

getSlugSource() protected method

Get the source string for the slug.
protected getSlugSource ( mixed $from ) : string
$from mixed
return string
    protected function getSlugSource($from)
    {
        if (is_null($from)) {
            return $this->model->__toString();
        }
        $sourceStrings = array_map(function ($key) {
            return data_get($this->model, $key);
        }, (array) $from);
        return join($sourceStrings, ' ');
    }