mirror of
https://github.com/restic/restic.git
synced 2025-03-23 00:00:04 +01:00
Add SecretString support for options
This commit is contained in:
parent
aab8a5f36f
commit
46c26643a7
1 changed files with 4 additions and 0 deletions
|
@ -211,6 +211,10 @@ func (o Options) Apply(ns string, dst interface{}) error {
|
|||
|
||||
v.Field(i).SetInt(int64(d))
|
||||
|
||||
case "SecretString":
|
||||
ss := NewSecretString(value)
|
||||
v.Field(i).Set(reflect.ValueOf(ss))
|
||||
|
||||
default:
|
||||
panic("type " + v.Type().Field(i).Type.Name() + " not handled")
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue