Unwatch directory
This commit is contained in:
committed by
Ben Johnson
parent
2c0dce21fa
commit
7d0167f10a
@@ -137,7 +137,7 @@ func (s *Server) Unwatch(path string) error {
|
|||||||
delete(s.dbs, path)
|
delete(s.dbs, path)
|
||||||
|
|
||||||
// Stop watching for changes on the database WAL.
|
// Stop watching for changes on the database WAL.
|
||||||
if err := s.watcher.Remove(path + "-wal"); err != nil {
|
if err := s.watcher.Remove(filepath.Dir(path)); err != nil {
|
||||||
return fmt.Errorf("unwatch file: %w", err)
|
return fmt.Errorf("unwatch file: %w", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user