ref: df1f2fb3daa1acd25c88510f259d5535fb482126
dir: /object/signed/commit/signature_algorithms.go/
package signedcommit
import objectid "codeberg.org/lindenii/furgit/object/id"
// Algorithms returns the algorithms for which the commit carries signatures.
func (commit *Commit) Algorithms() []objectid.Algorithm {
var algorithms []objectid.Algorithm
for _, algo := range objectid.SupportedAlgorithms() {
if _, ok := commit.signatures[algo]; ok {
algorithms = append(algorithms, algo)
}
}
return algorithms
}