apply options on newly added keyring types (#5404)
This commit is contained in:
committed by
Alessio Treglia
parent
0e28da23e7
commit
d7b0f4b9b4
@@ -56,13 +56,13 @@ func NewKeyring(
|
||||
}
|
||||
|
||||
// NewKeyringFile creates a new instance of an encrypted file-backed keyring.
|
||||
func NewKeyringFile(name string, dir string, userInput io.Reader) (Keybase, error) {
|
||||
func NewKeyringFile(name string, dir string, userInput io.Reader, opts ...KeybaseOption) (Keybase, error) {
|
||||
db, err := keyring.Open(newFileBackendKeyringConfig(name, dir, userInput))
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
return newKeyringKeybase(db), nil
|
||||
return newKeyringKeybase(db, opts...), nil
|
||||
}
|
||||
|
||||
// NewTestKeyring creates a new instance of an on-disk keyring for
|
||||
|
||||
Reference in New Issue
Block a user