From 92b9af02614c78f933a116f114a567845e0ba6ed Mon Sep 17 00:00:00 2001 From: Molly Struve Date: Fri, 28 Aug 2020 14:06:38 -0500 Subject: [PATCH] Bug Fix:Destroy Repos that We No Longer Have Credentials For (#10056) --- app/workers/github_repos/repo_sync_worker.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/workers/github_repos/repo_sync_worker.rb b/app/workers/github_repos/repo_sync_worker.rb index 8a836f456..a31be49f5 100644 --- a/app/workers/github_repos/repo_sync_worker.rb +++ b/app/workers/github_repos/repo_sync_worker.rb @@ -27,7 +27,7 @@ module GithubRepos info_hash: fetched_repo.to_hash, ) repo.user&.touch(:github_repos_updated_at) - rescue Github::Errors::NotFound + rescue Github::Errors::NotFound, Github::Errors::Unauthorized repo.destroy end end