We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d8b404b commit 0fb4af6Copy full SHA for 0fb4af6
share/settings/users.go
@@ -5,7 +5,6 @@ import (
5
"errors"
6
"fmt"
7
"io/ioutil"
8
- "path/filepath"
9
"regexp"
10
"sync"
11
@@ -103,15 +102,11 @@ func (u *UserIndex) addWatchEvents() error {
103
102
if err != nil {
104
return err
105
}
106
- configDir := filepath.Dir(u.configFile)
107
- if err := watcher.Add(configDir); err != nil {
+ if err := watcher.Add(u.configFile); err != nil {
108
109
110
go func() {
111
for e := range watcher.Events {
112
- if e.Name != u.configFile {
113
- continue
114
- }
115
if e.Op&fsnotify.Write != fsnotify.Write {
116
continue
117
0 commit comments