diff options
author | Ruben Pollan <meskio@sindominio.net> | 2020-09-30 12:35:07 +0200 |
---|---|---|
committer | Ruben Pollan <meskio@sindominio.net> | 2020-09-30 18:31:02 +0200 |
commit | 89b148d143870161909eb6170d4fc1840277aa94 (patch) | |
tree | e94cca65f0d092bf7d0a4707dba841c02bb046a2 /pkg/bitmask | |
parent | 5d102497e80f17056ce97bcc58a4906cf8a05c28 (diff) |
[feat] remove unused config options
Diffstat (limited to 'pkg/bitmask')
-rw-r--r-- | pkg/bitmask/init.go | 22 |
1 files changed, 2 insertions, 20 deletions
diff --git a/pkg/bitmask/init.go b/pkg/bitmask/init.go index 3e040b4..727d62a 100644 --- a/pkg/bitmask/init.go +++ b/pkg/bitmask/init.go @@ -19,7 +19,6 @@ import ( "log" "os" "path" - "strconv" "0xacab.org/leap/bitmask-vpn/pkg/config" "0xacab.org/leap/bitmask-vpn/pkg/vpn" @@ -35,14 +34,14 @@ type ProviderOpts struct { AppName string `json:"applicationName"` BinaryName string `json:"binaryName"` Auth string `json:"auth"` - AuthEmptyPass string `json:"authEmptyPass"` + AuthEmptyPass bool `json:"authEmptyPass"` ProviderURL string `json:"providerURL"` DonateURL string `json:"donateURL"` ApiURL string `json:"apiURL"` TosURL string `json:"tosURL"` HelpURL string `json:"helpURL"` GeolocationURL string `json:"geolocationAPI"` - AskForDonations string `json:"askForDonations"` + AskForDonations bool `json:"askForDonations"` CaCert string `json:"caCertString"` } @@ -54,28 +53,11 @@ func GetConfiguredProvider() *ProviderInfo { func ConfigureProvider(opts *ProviderOpts) { config.Provider = opts.ProviderURL - config.ProviderName = opts.Provider config.ApplicationName = opts.AppName config.BinaryName = opts.BinaryName config.Auth = opts.Auth - - config.DonateURL = opts.DonateURL - config.HelpURL = opts.HelpURL - config.TosURL = opts.TosURL - config.APIURL = opts.ApiURL config.GeolocationAPI = opts.GeolocationURL config.CaCert = []byte(opts.CaCert) - - wantsDonations, err := strconv.ParseBool(opts.AskForDonations) - if err == nil { - config.AskForDonations = wantsDonations - } - - emptyPass, err := strconv.ParseBool(opts.AuthEmptyPass) - if err == nil { - config.AuthEmptyPass = emptyPass - log.Println("DEBUG: provider allows empty pass:", emptyPass) - } } func InitializeLogger() { |