MCPcopy Create free account
hub / github.com/chainreactors/EvilProxy / ReloadConfigIfChanged

Method ReloadConfigIfChanged

internal/watcher/config_reload.go:44–49  ·  view source on GitHub ↗

ReloadConfigIfChanged runs the same config reload path used by filesystem events.

()

Source from the content-addressed store, hash-verified

42
43// ReloadConfigIfChanged runs the same config reload path used by filesystem events.
44func (w *Watcher) ReloadConfigIfChanged() {
45 if w == nil {
46 return
47 }
48 w.reloadConfigIfChanged()
49}
50
51func (w *Watcher) reloadConfigIfChanged() {
52 data, err := os.ReadFile(w.configPath)

Callers 1

defaultWatcherFactoryFunction · 0.95

Calls 1

reloadConfigIfChangedMethod · 0.95

Tested by

no test coverage detected