1
0
mirror of https://github.com/taigrr/wtf synced 2025-01-18 04:03:14 -08:00

Close #75. Github no longer crashes on network failure

This commit is contained in:
Chris Cummer 2018-05-30 21:58:41 -07:00
parent 7bf2ad88cf
commit 86d43e9af6

View File

@ -37,6 +37,10 @@ func (repo *GithubRepo) Refresh() {
/* -------------------- Counts -------------------- */
func (repo *GithubRepo) IssueCount() int {
if repo.RemoteRepo == nil {
return 0
}
return *repo.RemoteRepo.OpenIssuesCount
}
@ -45,6 +49,10 @@ func (repo *GithubRepo) PullRequestCount() int {
}
func (repo *GithubRepo) StarCount() int {
if repo.RemoteRepo == nil {
return 0
}
return *repo.RemoteRepo.StargazersCount
}