mirror of
https://github.com/koel/koel
synced 2024-12-22 10:33:16 +00:00
21 lines
547 B
PHP
21 lines
547 B
PHP
|
<?php
|
||
|
|
||
|
namespace App\Http\Controllers\API;
|
||
|
|
||
|
use App\Http\Controllers\Controller;
|
||
|
use App\Http\Requests\API\SetLastfmSessionKeyRequest;
|
||
|
use App\Models\User;
|
||
|
use App\Services\LastfmService;
|
||
|
use Illuminate\Contracts\Auth\Authenticatable;
|
||
|
|
||
|
class SetLastfmSessionKeyController extends Controller
|
||
|
{
|
||
|
/** @param User $user */
|
||
|
public function __invoke(SetLastfmSessionKeyRequest $request, LastfmService $lastfm, Authenticatable $user)
|
||
|
{
|
||
|
$lastfm->setUserSessionKey($user, $request->key);
|
||
|
|
||
|
return response()->noContent();
|
||
|
}
|
||
|
}
|