diff --git a/app/Http/Controllers/Profile/OAuthController.php b/app/Http/Controllers/Profile/OAuthController.php index 92dd6798c8..82fff226eb 100644 --- a/app/Http/Controllers/Profile/OAuthController.php +++ b/app/Http/Controllers/Profile/OAuthController.php @@ -120,8 +120,15 @@ final class OAuthController extends Controller { // Retrieving all the OAuth app clients that belong to the user... $clients = auth()->user()->oauthApps()->where('revoked', false)->get(); + $array = []; + /** @var Client $client */ + foreach($clients as $client) { + $item = $client->toArray(); + $item['confidential'] = $client->confidential(); + $array[] = $item; + } - return response()->json($clients); + return response()->json($array); } public function listPersonalAccessTokens(): JsonResponse diff --git a/config/translations.php b/config/translations.php index f58594f31a..4db6fbeb9e 100644 --- a/config/translations.php +++ b/config/translations.php @@ -141,6 +141,7 @@ return [ 'firefly' => [ 'explain_pats', 'profile_oauth_clients_explain', + 'regenerate_secret', 'administrations_page_title', 'administrations_index_menu', 'expires_at', diff --git a/public/v1/js/.gitkeep b/public/v1/js/.gitkeep old mode 100644 new mode 100755 diff --git a/resources/assets/v1/src/components/passport/Clients.vue b/resources/assets/v1/src/components/passport/Clients.vue index ddb4fbf729..063ca0d50e 100644 --- a/resources/assets/v1/src/components/passport/Clients.vue +++ b/resources/assets/v1/src/components/passport/Clients.vue @@ -52,7 +52,7 @@