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

Function UpdatePublicKey

internal/database/ssh_key.go:467–470  ·  view source on GitHub ↗

UpdatePublicKey updates given public key.

(key *PublicKey)

Source from the content-addressed store, hash-verified

465
466// UpdatePublicKey updates given public key.
467func UpdatePublicKey(key *PublicKey) error {
468 _, err := x.Id(key.ID).AllCols().Update(key)
469 return err
470}
471
472// deletePublicKeys does the actual key deletion but does not update authorized_keys file.
473func deletePublicKeys(e *xorm.Session, keyIDs ...int64) error {

Callers 1

runServFunction · 0.92

Calls 1

UpdateMethod · 0.65

Tested by

no test coverage detected