mirror of
https://github.com/samsonjs/retrogit.git
synced 2026-04-27 15:07:43 +00:00
Better handling for revoked credentials on the admin page.
This commit is contained in:
parent
8a05a55208
commit
2851ad3ac2
2 changed files with 10 additions and 2 deletions
|
|
@ -546,7 +546,9 @@ func usersAdminHandler(w http.ResponseWriter, r *http.Request) *AppError {
|
||||||
select {
|
select {
|
||||||
case r := <-ch:
|
case r := <-ch:
|
||||||
users = append(users, r)
|
users = append(users, r)
|
||||||
totalRepos += len(r.Repos.AllRepos)
|
if r.Repos != nil {
|
||||||
|
totalRepos += len(r.Repos.AllRepos)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
var data = map[string]interface{}{
|
var data = map[string]interface{}{
|
||||||
|
|
|
||||||
|
|
@ -22,7 +22,13 @@
|
||||||
{{range .Users}}
|
{{range .Users}}
|
||||||
<tr>
|
<tr>
|
||||||
<td><a href="{{routeUrl "digest-admin"}}?user_id={{.Account.GitHubUserId}}">{{.Account.GitHubUserId}}</a></td>
|
<td><a href="{{routeUrl "digest-admin"}}?user_id={{.Account.GitHubUserId}}">{{.Account.GitHubUserId}}</a></td>
|
||||||
<td>{{template "user" .User}}</td>
|
<td>
|
||||||
|
{{if .User}}
|
||||||
|
{{template "user" .User}}
|
||||||
|
{{else}}
|
||||||
|
User could not be looked up, credentials have most likely been revoked.
|
||||||
|
{{end}}
|
||||||
|
</td>
|
||||||
<td>{{.EmailAddress}}</td>
|
<td>{{.EmailAddress}}</td>
|
||||||
<td>{{.Account.Frequency}}</td>
|
<td>{{.Account.Frequency}}</td>
|
||||||
<td>
|
<td>
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue