diff options
author | kali kaneko (leap communications) <kali@leap.se> | 2020-06-17 19:40:24 +0200 |
---|---|---|
committer | kali kaneko (leap communications) <kali@leap.se> | 2020-06-26 12:13:43 +0200 |
commit | 9b8009cfaf6707d23a20494cd5467aed9c98513b (patch) | |
tree | 427ae34f6c32ba1dd4e182ac1def70c700b27e86 /pkg/backend/api.go | |
parent | 2bcaa8e89c2e76c2d14cf9f7f029e17d46c91e0f (diff) |
[feat] cleanup temp dirs on quit
Diffstat (limited to 'pkg/backend/api.go')
-rw-r--r-- | pkg/backend/api.go | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/pkg/backend/api.go b/pkg/backend/api.go index 5cb0304..74220ed 100644 --- a/pkg/backend/api.go +++ b/pkg/backend/api.go @@ -1,4 +1,4 @@ -/* All the exported functions live here */ +/* All the exported functions should be added here */ package backend @@ -24,7 +24,7 @@ func SwitchOff() { } func Unblock() { - //TODO + //TODO - fmt.Println("unblock... [not implemented]") } @@ -34,6 +34,7 @@ func Quit() { ctx.cfg.SetUserStoppedVPN(true) stopVPN() } + cleanupTempDirs() } func DonateAccepted() { @@ -51,10 +52,7 @@ func SubscribeToEvent(event string, f unsafe.Pointer) { func InitializeBitmaskContext() { p := bitmask.GetConfiguredProvider() - initOnce.Do(func() { - initializeContext( - p.Provider, p.AppName) - }) + initOnce.Do(func() { initializeContext(p.Provider, p.AppName) }) go ctx.updateStatus() go func() { |