mirror of
https://github.com/pocketbase/pocketbase.git
synced 2026-05-19 06:11:43 -04:00
[#7632] added missing error check in the jsvm watcher
This commit is contained in:
@@ -440,8 +440,8 @@ func (p *plugin) watchHooks() error {
|
||||
//
|
||||
// @todo replace once recursive watcher is added (https://github.com/fsnotify/fsnotify/issues/18)
|
||||
dirsErr := filepath.WalkDir(watchDir, func(path string, entry fs.DirEntry, err error) error {
|
||||
// ignore hidden directories, node_modules, symlinks, sockets, etc.
|
||||
if !entry.IsDir() || entry.Name() == "node_modules" || strings.HasPrefix(entry.Name(), ".") {
|
||||
// skip access failures, hidden directories, node_modules, etc.
|
||||
if err != nil || !entry.IsDir() || entry.Name() == "node_modules" || strings.HasPrefix(entry.Name(), ".") {
|
||||
return nil
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user