Commit
+5 -0 +/-1 browse
1 | diff --git a/pkg/internal/config.go b/pkg/internal/config.go |
2 | index d76fe4b..0df5cfb 100644 |
3 | --- a/pkg/internal/config.go |
4 | +++ b/pkg/internal/config.go |
5 | @@ -2,6 +2,7 @@ package pomo |
6 | |
7 | import ( |
8 | "encoding/json" |
9 | + "fmt" |
10 | "io/ioutil" |
11 | "os" |
12 | "path" |
13 | @@ -118,5 +119,9 @@ func LoadConfig(configPath string, config *Config) error { |
14 | if config.IconPath == "" { |
15 | config.IconPath = path.Join(config.BasePath, "/icon.png") |
16 | } |
17 | + if config.Publish && (config.PublishSocketPath == "" || config.PublishSocketPath == config.SocketPath) { |
18 | + return fmt.Errorf("'publish' option now requires 'publishSocketPath' which must not be the same as 'socketPath'") |
19 | + } |
20 | + |
21 | return nil |
22 | } |