func (e NoPGPEncryptionKeyError) ToStatus() keybase1.Status { ret := keybase1.Status{ Code: SCKeyNoPGPEncryption, Name: "SC_KEY_NO_PGP_ENCRYPTION", Desc: e.User, } if e.HasDeviceKey { ret.Fields = []keybase1.StringKVPair{ {"device", "1"}, } } return ret }
func (e NoNaClEncryptionKeyError) ToStatus() keybase1.Status { ret := keybase1.Status{ Code: SCKeyNoNaClEncryption, Name: "SC_KEY_NO_NACL_ENCRYPTION", Desc: e.User, } if e.HasPGPKey { ret.Fields = []keybase1.StringKVPair{ {"pgp", "1"}, } } return ret }
func (e NoMatchingGPGKeysError) ToStatus() keybase1.Status { s := keybase1.Status{ Code: SCKeyNoMatchingGPG, Name: "SC_KEY_NO_MATCHING_GPG", Fields: []keybase1.StringKVPair{ {"fingerprints", strings.Join(e.Fingerprints, ",")}, }, } if e.HasActiveDevice { s.Fields = append(s.Fields, keybase1.StringKVPair{Key: "has_active_device", Value: "1"}) } return s }