original_string: protected function deleteFilesAndImages($id)
      {
          $data = $this->model->with($this->getRelations())
              ->findOrFail($id)->toArray();
  
          $this->builder->fields()->filter(function ($field) {
              return $field instanceof Field\File;
          })->each(function (File $file) use ($data) {
              $file->setOriginal($data);
  
              $file->destroy();
          });
      }
code: protected function deleteFilesAndImages($id)
      {
          $data = $this->model->with($this->getRelations())
              ->findOrFail($id)->toArray();
  
          $this->builder->fields()->filter(function ($field) {
              return $field instanceof Field\File;
          })->each(function (File $file) use ($data) {
              $file->setOriginal($data);
  
              $file->destroy();
          });
      }
code_tokens: protected function deleteFilesAndImages ( $ id ) { $ data = $ this -> model -> with ( $ this -> getRelations ( ) ) -> findOrFail ( $ id ) -> toArray ( ) ; $ this -> builder -> fields ( ) -> filter ( function ( $ field ) { return $ field instanceof Field \ File ; } ) -> each ( function ( File $ file ) use ( $ data ) { $ file -> setOriginal ( $ data ) ; $ file -> destroy ( ) ; } ) ; }
docstring: Remove files or images in record.
  
  @param $id
docstring_tokens: Remove files or images in record .