This commit is contained in:
parent
151757cc8a
commit
b758ec854e
|
@ -352,17 +352,13 @@ func (sessions *wSessions) New(httpSession *sessions.Session, sid string) *WideS
|
||||||
return // release this gorutine
|
return // release this gorutine
|
||||||
}
|
}
|
||||||
|
|
||||||
logger.Info(event)
|
logger.Debug(event)
|
||||||
|
|
||||||
if event.Op&fsnotify.Create == fsnotify.Create {
|
if event.Op&fsnotify.Create == fsnotify.Create {
|
||||||
if err = watcher.Add(path); nil != err {
|
if err = watcher.Add(path); nil != err {
|
||||||
logger.Warn(err, path)
|
logger.Warn(err, path)
|
||||||
}
|
}
|
||||||
|
|
||||||
if util.File.IsDir(path) {
|
|
||||||
break
|
|
||||||
}
|
|
||||||
|
|
||||||
logger.Tracef("File watcher added a file [%s]", path)
|
logger.Tracef("File watcher added a file [%s]", path)
|
||||||
|
|
||||||
cmd := map[string]interface{}{"path": path, "dir": dir, "cmd": "create-file"}
|
cmd := map[string]interface{}{"path": path, "dir": dir, "cmd": "create-file"}
|
||||||
|
|
Loading…
Reference in New Issue