mirror of
https://github.com/koel/koel
synced 2024-12-21 10:03:10 +00:00
37 lines
847 B
PHP
37 lines
847 B
PHP
<?php
|
|
|
|
namespace App\Providers;
|
|
|
|
use App\Models\Playlist;
|
|
use App\Models\User;
|
|
use App\Policies\PlaylistPolicy;
|
|
use App\Policies\UserPolicy;
|
|
use Illuminate\Contracts\Auth\Access\Gate as GateContract;
|
|
use Illuminate\Foundation\Support\Providers\AuthServiceProvider as ServiceProvider;
|
|
|
|
class AuthServiceProvider extends ServiceProvider
|
|
{
|
|
/**
|
|
* The policy mappings for the application.
|
|
*
|
|
* @var array
|
|
*/
|
|
protected $policies = [
|
|
Playlist::class => PlaylistPolicy::class,
|
|
User::class => UserPolicy::class,
|
|
];
|
|
|
|
/**
|
|
* Register any application authentication / authorization services.
|
|
*
|
|
* @param \Illuminate\Contracts\Auth\Access\Gate $gate
|
|
*
|
|
* @return void
|
|
*/
|
|
public function boot(GateContract $gate)
|
|
{
|
|
$this->registerPolicies($gate);
|
|
|
|
//
|
|
}
|
|
}
|