(ctx context.Context)
| 210 | } |
| 211 | |
| 212 | func GetStatistic(ctx context.Context) (stats Statistic) { |
| 213 | stats.Counter.User = Handle.Users().Count(ctx) |
| 214 | stats.Counter.Org = CountOrganizations() |
| 215 | stats.Counter.PublicKey, _ = x.Count(new(PublicKey)) |
| 216 | stats.Counter.Repo = CountRepositories(true) |
| 217 | stats.Counter.Watch, _ = x.Count(new(Watch)) |
| 218 | stats.Counter.Star, _ = x.Count(new(Star)) |
| 219 | stats.Counter.Action, _ = x.Count(new(Action)) |
| 220 | stats.Counter.Access, _ = x.Count(new(Access)) |
| 221 | stats.Counter.Issue, _ = x.Count(new(Issue)) |
| 222 | stats.Counter.Comment, _ = x.Count(new(Comment)) |
| 223 | stats.Counter.Oauth = 0 |
| 224 | stats.Counter.Follow, _ = x.Count(new(Follow)) |
| 225 | stats.Counter.Mirror, _ = x.Count(new(Mirror)) |
| 226 | stats.Counter.Release, _ = x.Count(new(Release)) |
| 227 | stats.Counter.LoginSource = Handle.LoginSources().Count(ctx) |
| 228 | stats.Counter.Webhook, _ = x.Count(new(Webhook)) |
| 229 | stats.Counter.Milestone, _ = x.Count(new(Milestone)) |
| 230 | stats.Counter.Label, _ = x.Count(new(Label)) |
| 231 | stats.Counter.HookTask, _ = x.Count(new(HookTask)) |
| 232 | stats.Counter.Team, _ = x.Count(new(Team)) |
| 233 | stats.Counter.Attachment, _ = x.Count(new(Attachment)) |
| 234 | return stats |
| 235 | } |
| 236 | |
| 237 | func Ping() error { |
| 238 | if x == nil { |
no test coverage detected