Programming Language PHP

Namespace Plank\Mediable\Helpers

Class File

Method/Function sanitizeFileName

Total Examples 1

1 code examples of PHP Plank\Mediable\Helpers\File::sanitizeFileName extracted from open source projects

Was this example useful?
0
                                                    /**
     * Generate the model's filename.
     */
    private function generateFilename(): string
    {
        if ($this->filename) {
            return $this->filename;
        }

        if ($this->hashFilename) {
            return $this->generateHash();
        }

        return File::sanitizeFileName($this->source->filename());
    }