public function slug(Model $model, $force = false)
{
$this->setModel($model);
$attributes = [];
foreach ($this->model->sluggable() as $attribute => $config) {
if (is_numeric($attribute)) {
$attribute = $config;
$config = $this->getConfiguration();
} else {
$config = $this->getConfiguration($config);
}
$slug = $this->buildSlug($attribute, $config, $force);
$this->model->setAttribute($attribute, $slug);
$attributes[] = $attribute;
}
return $this->model->isDirty($attributes);
}