protected function getDiff($model)
    {
        $dirty = $model->getDirty();
        $fresh = $model->fresh() ? $model->fresh()->toArray() : []; 
        $after = json_encode($dirty);
        $before = json_encode(array_intersect_key($fresh, $dirty));

        return compact('before', 'after');
    }