diff options
author | Ruben Pollan <meskio@sindominio.net> | 2018-06-14 11:29:26 +0200 |
---|---|---|
committer | Ruben Pollan <meskio@sindominio.net> | 2018-06-20 12:18:17 +0200 |
commit | 2439d744ac42e7c77e4848de50dd432f7d9b12bc (patch) | |
tree | 43cd32185b96a2353f6bbbea407494d8644d8801 /config.go | |
parent | 37413f5eb2b8d4719c959db03874cc9bcc362ddc (diff) |
[feat] sort gateways by timezone
And let us select gateways.
- Resolves: #42
Diffstat (limited to 'config.go')
-rw-r--r-- | config.go | 9 |
1 files changed, 1 insertions, 8 deletions
@@ -17,7 +17,6 @@ package main import ( "encoding/json" - "flag" "os" "path" "time" @@ -37,7 +36,7 @@ var ( type systrayConfig struct { LastNotification time.Time Donated time.Time - SelectWateway bool + SelectGateway bool UserStoppedVPN bool } @@ -53,7 +52,6 @@ func parseConfig() *systrayConfig { dec := json.NewDecoder(f) err = dec.Decode(&conf) - conf.parseFlags() return &conf } @@ -62,11 +60,6 @@ func (c *systrayConfig) setUserStoppedVPN(vpnStopped bool) error { return c.save() } -func (c *systrayConfig) parseFlags() { - flag.BoolVar(&c.SelectWateway, "select-gateway", false, "Enable gateway selection") - flag.Parse() -} - func (c *systrayConfig) hasDonated() bool { return c.Donated.Add(oneMonth).After(time.Now()) } |