Skip to content

Commit e8ddcb3

Browse files
committed
rm dead code
1 parent 2bc9447 commit e8ddcb3

File tree

1 file changed

+0
-51
lines changed

1 file changed

+0
-51
lines changed

src/github/client.ts

Lines changed: 0 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -181,26 +181,6 @@ export class GitHubClient {
181181
return await response.json();
182182
}
183183

184-
async createPRComment(
185-
owner: string,
186-
repo: string,
187-
prNumber: number,
188-
body: string
189-
): Promise<any> {
190-
const url = `${this.baseUrl}/repos/${owner}/${repo}/issues/${prNumber}/comments`;
191-
192-
const response = await this.makeRequest(url, {
193-
method: 'POST',
194-
body: JSON.stringify({ body }),
195-
});
196-
197-
if (!response.ok) {
198-
const errorText = await response.text();
199-
throw new Error(`GitHub API error: ${response.status} ${response.statusText} - ${errorText}`);
200-
}
201-
202-
return await response.json();
203-
}
204184

205185
async createPRReview(
206186
owner: string,
@@ -238,23 +218,6 @@ export class GitHubClient {
238218
return await response.json();
239219
}
240220

241-
async getPRDiff(owner: string, repo: string, prNumber: number): Promise<string> {
242-
const url = `${this.baseUrl}/repos/${owner}/${repo}/pulls/${prNumber}`;
243-
244-
const response = await this.makeRequest(url, {
245-
method: 'GET',
246-
headers: {
247-
'Accept': 'application/vnd.github.v3.diff',
248-
},
249-
});
250-
251-
if (!response.ok) {
252-
const errorText = await response.text();
253-
throw new Error(`GitHub API error: ${response.status} ${response.statusText} - ${errorText}`);
254-
}
255-
256-
return await response.text();
257-
}
258221

259222
async getPRInfo(owner: string, repo: string, prNumber: number): Promise<any> {
260223
const url = `${this.baseUrl}/repos/${owner}/${repo}/pulls/${prNumber}`;
@@ -271,20 +234,6 @@ export class GitHubClient {
271234
return await response.json();
272235
}
273236

274-
async getRepositoryInfo(owner: string, repo: string): Promise<any> {
275-
const url = `${this.baseUrl}/repos/${owner}/${repo}`;
276-
277-
const response = await this.makeRequest(url, {
278-
method: 'GET',
279-
});
280-
281-
if (!response.ok) {
282-
const errorText = await response.text();
283-
throw new Error(`GitHub API error: ${response.status} ${response.statusText} - ${errorText}`);
284-
}
285-
286-
return await response.json();
287-
}
288237

289238
async getPRFiles(owner: string, repo: string, prNumber: number): Promise<any[]> {
290239
const url = `${this.baseUrl}/repos/${owner}/${repo}/pulls/${prNumber}/files`;

0 commit comments

Comments
 (0)