original_string: private function saveOriginalFile(UploadedFile $uploadedFile)
      {
          try {
              $targetFilepath = implode('/', [
                  $this->results['path'], $this->results['filename'],
              ]);
  
              $image = $this->intervention->make($uploadedFile);
  
              if ($this->exif && ! empty($image->exif())) {
                  $this->results['exif'] = $image->exif();
              }
  
              $image->save($targetFilepath, $this->quality);
  
              // Save to s3
              $s3_url = $this->saveToS3($image, $targetFilepath);
  
              $this->results['original_width'] = (int) $image->width();
              $this->results['original_height'] = (int) $image->height();
              $this->results['original_filepath'] = $targetFilepath;
              $this->results['original_filedir'] = $this->getRelativePath($targetFilepath);
              $this->results['s3_url'] = $s3_url;
          } catch (Exception $e) {
              throw new ImageuploadException($e->getMessage());
          }
  
          return $this;
      }
code: private function saveOriginalFile(UploadedFile $uploadedFile)
      {
          try {
              $targetFilepath = implode('/', [
                  $this->results['path'], $this->results['filename'],
              ]);
  
              $image = $this->intervention->make($uploadedFile);
  
              if ($this->exif && ! empty($image->exif())) {
                  $this->results['exif'] = $image->exif();
              }
  
              $image->save($targetFilepath, $this->quality);
  
              // Save to s3
              $s3_url = $this->saveToS3($image, $targetFilepath);
  
              $this->results['original_width'] = (int) $image->width();
              $this->results['original_height'] = (int) $image->height();
              $this->results['original_filepath'] = $targetFilepath;
              $this->results['original_filedir'] = $this->getRelativePath($targetFilepath);
              $this->results['s3_url'] = $s3_url;
          } catch (Exception $e) {
              throw new ImageuploadException($e->getMessage());
          }
  
          return $this;
      }
code_tokens: private function saveOriginalFile ( UploadedFile $ uploadedFile ) { try { $ targetFilepath = implode ( '/' , [ $ this -> results [ 'path' ] , $ this -> results [ 'filename' ] , ] ) ; $ image = $ this -> intervention -> make ( $ uploadedFile ) ; if ( $ this -> exif && ! empty ( $ image -> exif ( ) ) ) { $ this -> results [ 'exif' ] = $ image -> exif ( ) ; } $ image -> save ( $ targetFilepath , $ this -> quality ) ; // Save to s3 $ s3_url = $ this -> saveToS3 ( $ image , $ targetFilepath ) ; $ this -> results [ 'original_width' ] = ( int ) $ image -> width ( ) ; $ this -> results [ 'original_height' ] = ( int ) $ image -> height ( ) ; $ this -> results [ 'original_filepath' ] = $ targetFilepath ; $ this -> results [ 'original_filedir' ] = $ this -> getRelativePath ( $ targetFilepath ) ; $ this -> results [ 's3_url' ] = $ s3_url ; } catch ( Exception $ e ) { throw new ImageuploadException ( $ e -> getMessage ( ) ) ; } return $ this ; }
docstring: Upload and save original file.
  
  @access private
  @param UploadedFile $uploadedFile
docstring_tokens: Upload and save original file .