Merge pull request #622 from bradrydzewski/master

fixes #620
This commit is contained in:
Brad Rydzewski 2014-10-24 09:11:43 -07:00
commit 39a9b2f316

View file

@ -225,8 +225,7 @@ func CreateUpdateKey(client *github.Client, owner, name, title, key string) (*gi
if k != nil {
k.Title = github.String(title)
k.Key = github.String(key)
var updated, _, err = client.Repositories.EditKey(owner, name, *k.ID, k)
return updated, err
client.Repositories.DeleteKey(owner, name, *k.ID)
}
return CreateKey(client, owner, name, title, key)