diff options
author | Michael Muré <batolettre@gmail.com> | 2023-08-12 14:05:02 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-12 14:05:02 +0200 |
commit | 20e62977a0509e2c79ef5d8d9173103a278b78ff (patch) | |
tree | 9a39ab11d0373caeaf34f2d06188c481d27f67d7 /entities/identity | |
parent | a0d225ce23af9f5dbe31521f19485c66d409e573 (diff) | |
parent | 429b913dc5519babfab47bf65222e32415a6c1bd (diff) | |
download | git-bug-20e62977a0509e2c79ef5d8d9173103a278b78ff.tar.gz |
Merge pull request #1088 from MichaelMure/dependabot/go_modules/github.com/99designs/gqlgen-0.17.36
build(deps): bump github.com/99designs/gqlgen from 0.17.20 to 0.17.36
Diffstat (limited to 'entities/identity')
-rw-r--r-- | entities/identity/key.go | 19 |
1 files changed, 8 insertions, 11 deletions
diff --git a/entities/identity/key.go b/entities/identity/key.go index 87271dd5..5ded31fa 100644 --- a/entities/identity/key.go +++ b/entities/identity/key.go @@ -217,18 +217,15 @@ func (k *Key) storePrivate(repo repository.RepoKeyring) error { } func (k *Key) PGPEntity() *openpgp.Entity { - uid := packet.NewUserId("", "", "") - return &openpgp.Entity{ + e := &openpgp.Entity{ PrimaryKey: k.public, PrivateKey: k.private, - Identities: map[string]*openpgp.Identity{ - uid.Id: { - Name: uid.Id, - UserId: uid, - SelfSignature: &packet.Signature{ - IsPrimaryId: func() *bool { b := true; return &b }(), - }, - }, - }, + Identities: map[string]*openpgp.Identity{}, + } + // somehow initialize the proper fields with identity, self-signature ... + err := e.AddUserId("name", "", "", nil) + if err != nil { + panic(err) } + return e } |