the browser-facing portion of osu!
at master 688 B view raw
1<?php 2 3// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the GNU Affero General Public License v3.0. 4// See the LICENCE file in the repository root for full licence text. 5 6namespace App\Http\Controllers\OAuth; 7 8use App\Http\Controllers\Controller; 9use App\Models\OAuth\Client; 10 11class AuthorizedClientsController extends Controller 12{ 13 public function __construct() 14 { 15 parent::__construct(); 16 17 $this->middleware('auth'); 18 $this->middleware('verify-user'); 19 } 20 21 public function destroy($clientId) 22 { 23 $client = Client::findOrFail($clientId); 24 $client->revokeForUser(auth()->user()); 25 26 return response(null, 204); 27 } 28}