Code maintenance: GetPassword signature changed
This commit is contained in:
@@ -18,15 +18,13 @@ func (r *reader) GetUser() (user string, err error) {
|
||||
}
|
||||
|
||||
// GetPassword obtains the password to use to connect to the VPN servers.
|
||||
func (r *reader) GetPassword(required bool) (s string, err error) {
|
||||
func (r *reader) GetPassword() (s string, err error) {
|
||||
options := []libparams.GetEnvSetter{
|
||||
libparams.CaseSensitiveValue(),
|
||||
libparams.Unset(),
|
||||
libparams.Compulsory(),
|
||||
libparams.RetroKeys([]string{"PASSWORD"}, r.onRetroActive),
|
||||
}
|
||||
if required {
|
||||
options = append(options, libparams.Compulsory())
|
||||
}
|
||||
return r.envParams.GetEnv("OPENVPN_PASSWORD", options...)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user