koel/app/Http/Controllers/Controller.php

22 lines
568 B
PHP
Raw Normal View History

2015-12-13 04:42:28 +00:00
<?php
namespace App\Http\Controllers;
2015-12-14 13:22:39 +00:00
use Illuminate\Foundation\Auth\Access\AuthorizesRequests;
2015-12-13 04:42:28 +00:00
use Illuminate\Foundation\Bus\DispatchesJobs;
use Illuminate\Foundation\Validation\ValidatesRequests;
2024-02-25 19:32:53 +00:00
use Illuminate\Http\Response;
2015-12-14 13:22:39 +00:00
use Illuminate\Routing\Controller as BaseController;
2015-12-13 04:42:28 +00:00
abstract class Controller extends BaseController
{
use AuthorizesRequests;
use DispatchesJobs;
use ValidatesRequests;
2024-02-25 19:32:53 +00:00
protected static function disableInDemo(int $code = Response::HTTP_FORBIDDEN): void
{
abort_if(config('koel.misc.demo'), $code);
}
2015-12-13 04:42:28 +00:00
}