Programming Language PHP

Namespace Plank\Mediable\Exceptions

Class MediaUrlException

Method/Function temporaryUrlsNotSupported

Total Examples 1

1 code examples of PHP Plank\Mediable\Exceptions\MediaUrlException::temporaryUrlsNotSupported extracted from open source projects

Was this example useful?
0
                                                    public function getTemporaryUrl(\DateTimeInterface $expiry): string
    {
        $generator = $this->getUrlGenerator();
        if ($generator instanceof TemporaryUrlGeneratorInterface) {
            return $generator->getTemporaryUrl($expiry);
        }

        throw MediaUrlException::temporaryUrlsNotSupported($this->disk);
    }