perf: improve the perf of Anonymous GitHub

This commit is contained in:
tdurieux
2023-02-08 09:49:24 +01:00
parent 73f7582fd2
commit 2e36b72a7f
12 changed files with 115 additions and 53 deletions

View File

@@ -39,7 +39,7 @@ export default class GitHubStream extends GitHubBase implements SourceBase {
const ghRes = await octokit.rest.git.getBlob({
owner: this.githubRepository.owner,
repo: this.githubRepository.repo,
file_sha: file.sha,
file_sha: await file.sha(),
});
if (!ghRes.data.content && ghRes.data.size != 0) {
throw new AnonymousError("file_not_accessible", {