mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-06-07 05:42:42 +00:00
fix gpg setting
Init is actually never called and I have no clue why it is there if it is not called. Take this opportunity to introduce a New function which only does the helper lookup and panics iff that fails. Panic may be a bit too aggressive, but seems the most certain way to get out of not finding a suitable gpg1 binary.
This commit is contained in:
+2
-2
@@ -400,7 +400,7 @@ func (context *AptlyContext) GetSigner() pgp.Signer {
|
||||
defer context.Unlock()
|
||||
|
||||
if context.pgpProvider() == "gpg" { // nolint: goconst
|
||||
return &pgp.GpgSigner{}
|
||||
return pgp.NewGpgSigner()
|
||||
}
|
||||
|
||||
return &pgp.GoSigner{}
|
||||
@@ -412,7 +412,7 @@ func (context *AptlyContext) GetVerifier() pgp.Verifier {
|
||||
defer context.Unlock()
|
||||
|
||||
if context.pgpProvider() == "gpg" { // nolint: goconst
|
||||
return &pgp.GpgVerifier{}
|
||||
return pgp.NewGpgVerifier()
|
||||
}
|
||||
|
||||
return &pgp.GoVerifier{}
|
||||
|
||||
Reference in New Issue
Block a user