summaryrefslogtreecommitdiff
path: root/notificator.go
diff options
context:
space:
mode:
authorRuben Pollan <meskio@sindominio.net>2018-06-20 11:40:44 +0200
committerRuben Pollan <meskio@sindominio.net>2018-06-20 11:40:44 +0200
commit95bc8b92bb4ade116f96ffcb2b40c42652acb37c (patch)
tree9537ada97e22550638cccb7ed79bdeb36df2f334 /notificator.go
parent0358eda7e3b56282383877f82aab1abc96c7f627 (diff)
[feat] return the correct svg path for snap
Diffstat (limited to 'notificator.go')
-rw-r--r--notificator.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/notificator.go b/notificator.go
index 8d0ee18..a69bdb0 100644
--- a/notificator.go
+++ b/notificator.go
@@ -99,6 +99,11 @@ func (n *notificator) errorStartingVPN(err error) {
}
func getSVGPath() string {
+ snapPath := os.Getenv("SNAP")
+ if snapPath != "" {
+ return snapPath + "/snap/gui/riseupvpn.svg"
+ }
+
wd, _ := os.Getwd()
svgPath := path.Join(wd, svgFileName)
if fileExist(svgPath) {