mirror of
https://github.com/koel/koel
synced 2024-12-12 13:42:27 +00:00
21 lines
568 B
PHP
21 lines
568 B
PHP
<?php
|
|
|
|
namespace App\Http\Controllers;
|
|
|
|
use Illuminate\Foundation\Auth\Access\AuthorizesRequests;
|
|
use Illuminate\Foundation\Bus\DispatchesJobs;
|
|
use Illuminate\Foundation\Validation\ValidatesRequests;
|
|
use Illuminate\Http\Response;
|
|
use Illuminate\Routing\Controller as BaseController;
|
|
|
|
abstract class Controller extends BaseController
|
|
{
|
|
use AuthorizesRequests;
|
|
use DispatchesJobs;
|
|
use ValidatesRequests;
|
|
|
|
protected static function disableInDemo(int $code = Response::HTTP_FORBIDDEN): void
|
|
{
|
|
abort_if(config('koel.misc.demo'), $code);
|
|
}
|
|
}
|