2024-01-03 17:02:18 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace App\Facades;
|
|
|
|
|
2024-03-30 16:49:25 +00:00
|
|
|
use App\Exceptions\KoelPlusRequiredException;
|
2024-01-03 17:02:18 +00:00
|
|
|
use Illuminate\Support\Facades\Facade;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @method static bool isPlus()
|
|
|
|
* @method static bool isCommunity()
|
2024-01-11 16:52:55 +00:00
|
|
|
* @see \App\Services\LicenseService
|
2024-01-03 17:02:18 +00:00
|
|
|
*/
|
|
|
|
class License extends Facade
|
|
|
|
{
|
2024-03-30 16:49:25 +00:00
|
|
|
public static function requirePlus(): void
|
|
|
|
{
|
|
|
|
throw_unless(static::isPlus(), KoelPlusRequiredException::class);
|
|
|
|
}
|
|
|
|
|
2024-01-03 17:02:18 +00:00
|
|
|
protected static function getFacadeAccessor(): string
|
|
|
|
{
|
|
|
|
return 'License';
|
|
|
|
}
|
|
|
|
}
|