MCPcopy Create free account
hub / github.com/gogs/gogs / GetContent

Method GetContent

internal/database/ssh_key.go:599–606  ·  view source on GitHub ↗

GetContent gets associated public key content.

()

Source from the content-addressed store, hash-verified

597
598// GetContent gets associated public key content.
599func (k *DeployKey) GetContent() error {
600 pkey, err := GetPublicKeyByID(k.KeyID)
601 if err != nil {
602 return err
603 }
604 k.Content = pkey.Content
605 return nil
606}
607
608func checkDeployKey(e Engine, keyID, repoID int64, name string) error {
609 // Note: We want error detail, not just true or false here.

Callers

nothing calls this directly

Calls 1

GetPublicKeyByIDFunction · 0.85

Tested by

no test coverage detected