spf13--viper/watch_disabled.go
Mark Sagi-Kazar c933cfd4f6
feat: disable watcher on aix
Signed-off-by: Mark Sagi-Kazar <mark.sagikazar@gmail.com>
2022-11-03 17:33:02 +01:00

31 lines
451 B
Go

//go:build js || aix
// +build js aix
package viper
import (
"errors"
"github.com/fsnotify/fsnotify"
)
type watcher struct {
Events chan fsnotify.Event
Errors chan error
}
func (*watcher) Close() error {
return nil
}
func (*watcher) Add(name string) error {
return nil
}
func (*watcher) Remove(name string) error {
return nil
}
func newWatcher() (*watcher, error) {
return &watcher{}, errors.New("fsnotify is not supported on WASM")
}