diff --git a/github/githubclient/client.go b/github/githubclient/client.go index 8c87bd0..f81bf15 100644 --- a/github/githubclient/client.go +++ b/github/githubclient/client.go @@ -4,7 +4,6 @@ import ( "bytes" "context" "fmt" - "gopkg.in/yaml.v3" "net/url" "os" "path" @@ -12,6 +11,8 @@ import ( "regexp" "strings" + "gopkg.in/yaml.v3" + "github.com/ejoffe/spr/config" "github.com/ejoffe/spr/git" "github.com/ejoffe/spr/github" @@ -264,11 +265,14 @@ func (c *client) GetAssignableUsers(ctx context.Context) []github.RepoAssignee { } for _, node := range *resp.Repository.AssignableUsers.Nodes { - users = append(users, github.RepoAssignee{ + user := github.RepoAssignee{ ID: node.Id, Login: node.Login, - Name: *node.Name, - }) + } + if node.Name != nil { + user.Name = *node.Name + } + users = append(users, user) } if !resp.Repository.AssignableUsers.PageInfo.HasNextPage { break