diff --git a/go/src/gopenpgpwrapper/gopenpgpwrapper.go b/go/src/gopenpgpwrapper/gopenpgpwrapper.go index 1e93bed..cf96b08 100644 --- a/go/src/gopenpgpwrapper/gopenpgpwrapper.go +++ b/go/src/gopenpgpwrapper/gopenpgpwrapper.go @@ -10,6 +10,10 @@ import ( ) type Key struct { + kr crypto.KeyRing +} + +func (k *Key) GetKeyID() string { if len(k.kr.GetEntities()) > 0 { return k.kr.GetEntities()[0].PrimaryKey.KeyIdShortString() } else { @@ -17,10 +21,6 @@ type Key struct { } } -func (k *Key) GetKeyID() string { - return k.kr.FirstKeyID -} - func (k *Key) Encrypt(plaintext []byte, armor bool) []byte { var b bytes.Buffer var w io.WriteCloser