public function saveFile(UploadedFile $file)
    {
        Validator::validate(
            [$this->getName() => $file],
            $this->getUploadValidationRules(),
            $this->getUploadValidationMessages(),
            $this->getUploadValidationTitles()
        );

        $path = $file->storeAs(
            $this->getUploadPath($file),
            $this->getUploadFileName($file),
            $this->getDisk()
        );

        return $this->getFileInfo($path);
    }
public function saveFile(UploadedFile $file)
    {
        Validator::validate(
            [$this->getName() => $file],
            $this->getUploadValidationRules(),
            $this->getUploadValidationMessages(),
            $this->getUploadValidationTitles()
        );

        $path = $file->storeAs(
            $this->getUploadPath($file),
            $this->getUploadFileName($file),
            $this->getDisk()
        );

        return $this->getFileInfo($path);
    }
public function saveFile ( UploadedFile $ file ) { Validator :: validate ( [ $ this -> getName ( ) => $ file ] , $ this -> getUploadValidationRules ( ) , $ this -> getUploadValidationMessages ( ) , $ this -> getUploadValidationTitles ( ) ) ; $ path = $ file -> storeAs ( $ this -> getUploadPath ( $ file ) , $ this -> getUploadFileName ( $ file ) , $ this -> getDisk ( ) ) ; return $ this -> getFileInfo ( $ path ) ; }
Save file to storage

@param \Illuminate\Http\UploadedFile $file

@return array
@throws \Illuminate\Validation\ValidationException
Save file to storage