original_string: protected function resolveTransformerFromModel(Model $model)
      {
          if (! $model instanceof Transformable) {
              return function ($model) {
                  return $model->toArray();
              };
          }
  
          return $model::transformer();
      }
code: protected function resolveTransformerFromModel(Model $model)
      {
          if (! $model instanceof Transformable) {
              return function ($model) {
                  return $model->toArray();
              };
          }
  
          return $model::transformer();
      }
code_tokens: protected function resolveTransformerFromModel ( Model $ model ) { if ( ! $ model instanceof Transformable ) { return function ( $ model ) { return $ model -> toArray ( ) ; } ; } return $ model :: transformer ( ) ; }
docstring: Resolve a transformer from the model. If the model is not transformable, a closure
  based transformer will be created instead, from the model's fillable attributes.
  
  @param  \Illuminate\Database\ELoquent\Model $model
  @return \Flugg\Responder\Transformer|callable
docstring_tokens: Resolve a transformer from the model . If the model is not transformable a closure based transformer will be created instead from the model s fillable attributes .