fix naming

This commit is contained in:
peaklabs-dev
2024-12-03 14:43:11 +01:00
parent a2860971a6
commit 6d43bbc6b9

View File

@@ -151,14 +151,14 @@ class Change extends Component
public function syncGithubAppName() public function syncGithubAppName()
{ {
try { try {
$jwt = $this->github_app->generateJWT(); $github_access_token = generate_github_installation_token($this->github_app);
$response = Http::withToken($jwt) $response = Http::withToken($github_access_token)
->withHeaders([ ->withHeaders([
'Accept' => 'application/vnd.github+json', 'Accept' => 'application/vnd.github+json',
'X-GitHub-Api-Version' => '2022-11-28', 'X-GitHub-Api-Version' => '2022-11-28',
]) ])
->get('https://api.github.com/app'); ->get("{$this->github_app->api_url}/app");
if ($response->successful()) { if ($response->successful()) {
$app_data = $response->json(); $app_data = $response->json();