diff options
| author | 2022-11-08 11:30:29 +0100 | |
|---|---|---|
| committer | 2022-11-08 11:30:29 +0100 | |
| commit | be011b164168ae5c1ae7b8a0c11c392187701766 (patch) | |
| tree | 4ea275ab207ec4724a71f2c327034065589a5402 /vendor/github.com/spf13/viper/viper.go | |
| parent | [chore]: Bump github.com/stretchr/testify from 1.8.0 to 1.8.1 (#1002) (diff) | |
| download | gotosocial-be011b164168ae5c1ae7b8a0c11c392187701766.tar.xz | |
[chore]: Bump github.com/spf13/viper from 1.13.0 to 1.14.0 (#1003)
Bumps [github.com/spf13/viper](https://github.com/spf13/viper) from 1.13.0 to 1.14.0.
- [Release notes](https://github.com/spf13/viper/releases)
- [Commits](https://github.com/spf13/viper/compare/v1.13.0...v1.14.0)
---
updated-dependencies:
- dependency-name: github.com/spf13/viper
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Diffstat (limited to 'vendor/github.com/spf13/viper/viper.go')
| -rw-r--r-- | vendor/github.com/spf13/viper/viper.go | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/vendor/github.com/spf13/viper/viper.go b/vendor/github.com/spf13/viper/viper.go index 5f76cc095..5c12529b4 100644 --- a/vendor/github.com/spf13/viper/viper.go +++ b/vendor/github.com/spf13/viper/viper.go @@ -463,9 +463,8 @@ func (v *Viper) WatchConfig() { // we only care about the config file with the following cases: // 1 - if the config file was modified or created // 2 - if the real path to the config file changed (eg: k8s ConfigMap replacement) - const writeOrCreateMask = fsnotify.Write | fsnotify.Create if (filepath.Clean(event.Name) == configFile && - event.Op&writeOrCreateMask != 0) || + (event.Has(fsnotify.Write) || event.Has(fsnotify.Create))) || (currentConfigFile != "" && currentConfigFile != realConfigFile) { realConfigFile = currentConfigFile err := v.ReadInConfig() @@ -475,8 +474,7 @@ func (v *Viper) WatchConfig() { if v.onConfigChange != nil { v.onConfigChange(event) } - } else if filepath.Clean(event.Name) == configFile && - event.Op&fsnotify.Remove != 0 { + } else if filepath.Clean(event.Name) == configFile && event.Has(fsnotify.Remove) { eventsWG.Done() return } |
