* Follow GitHub Response URL
( account: Account, url: Link, )
| 197 | * Follow GitHub Response URL |
| 198 | */ |
| 199 | async function followUrl<TResult>( |
| 200 | account: Account, |
| 201 | url: Link, |
| 202 | ): Promise<TResult> { |
| 203 | const octokit = await createOctokitClient(account, 'rest'); |
| 204 | |
| 205 | // Perform a generic GET request using Octokit's request method and cast the response type |
| 206 | const response = await octokit.request('GET {+url}', { |
| 207 | url: url, |
| 208 | }); |
| 209 | |
| 210 | return response.data as TResult; |
| 211 | } |
| 212 | |
| 213 | /** |
| 214 | * Fetch GitHub Discussion by Discussion Number. |
no test coverage detected