<?php

namespace Kylin\Media\Support;

use Kylin\Media\MediaCollections\Exceptions\FunctionalityNotAvailable;
use Kylin\MediaPro\Models\TemporaryUpload;

class MediaLibraryPro
{
    public static function ensureInstalled(): void
    {
        if (! self::isInstalled()) {
            throw FunctionalityNotAvailable::mediaLibraryProRequired();
        }
    }

    public static function isInstalled(): bool
    {
        return class_exists(TemporaryUpload::class);
    }
}
