getClientForIdentity return a githubv4 API client configured with the access token of the given identity.
(userId entity.Id)
| 119 | |
| 120 | // getClientForIdentity return a githubv4 API client configured with the access token of the given identity. |
| 121 | func (ge *githubExporter) getClientForIdentity(userId entity.Id) (*rateLimitHandlerClient, error) { |
| 122 | client, ok := ge.identityClient[userId] |
| 123 | if ok { |
| 124 | return client, nil |
| 125 | } |
| 126 | |
| 127 | return nil, ErrMissingIdentityToken |
| 128 | } |
| 129 | |
| 130 | // ExportAll export all event made by the current user to Github |
| 131 | func (ge *githubExporter) ExportAll(ctx context.Context, repo *cache.RepoCache, since time.Time) (<-chan core.ExportResult, error) { |