Skip to content

Commit

Permalink
chore: remove unnecessary console logs
Browse files Browse the repository at this point in the history
Signed-off-by: Victor Yanev <victor.yanev@limechain.tech>
  • Loading branch information
victor-yanev committed Jul 19, 2024
1 parent aa6dd42 commit d627d17
Showing 1 changed file with 3 additions and 7 deletions.
10 changes: 3 additions & 7 deletions packages/server/tests/clients/githubClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,13 +65,11 @@ export class GitHubClient {
async getCommentsOnPullRequest() {
try {
const context = GitHubClient.getContext();
const response = await this.octokit.request(GitHubClient.GET_COMMENTS_ENDPOINT, {
return await this.octokit.request(GitHubClient.GET_COMMENTS_ENDPOINT, {
owner: context.owner,
repo: context.repo,
issue_number: context.pullNumber,
});
console.debug('Comments retrieved successfully:', response);
return response;
} catch (error) {
console.error('Failed to retrieve comments on PR:', error);
return { data: [] };
Expand All @@ -87,13 +85,12 @@ export class GitHubClient {
async updateCommentOnPullRequest(commentBody: string, commentId: number): Promise<void> {
try {
const context = GitHubClient.getContext();
const response = await this.octokit.request(GitHubClient.UPDATE_COMMENT_ENDPOINT, {
await this.octokit.request(GitHubClient.UPDATE_COMMENT_ENDPOINT, {
owner: context.owner,
repo: context.repo,
comment_id: commentId,
body: commentBody,
});
console.debug('Comment updated successfully:', response);
} catch (error) {
console.error('Failed to update comment on PR:', error);
}
Expand All @@ -107,13 +104,12 @@ export class GitHubClient {
async addCommentToPullRequest(commentBody: string): Promise<void> {
try {
const context = GitHubClient.getContext();
const response = await this.octokit.request(GitHubClient.CREATE_COMMENT_ENDPOINT, {
await this.octokit.request(GitHubClient.CREATE_COMMENT_ENDPOINT, {
owner: context.owner,
repo: context.repo,
issue_number: context.pullNumber,
body: commentBody,
});
console.debug('Comment posted successfully:', response);
} catch (error) {
console.error('Failed to post comment to PR:', error);
}
Expand Down

0 comments on commit d627d17

Please sign in to comment.