fix: code style (#1342)

pull/1367/head
包子 3 years ago committed by GitHub
parent b44e47b087
commit 817c13a80c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      config/env/watcher.go

@ -20,11 +20,9 @@ func NewWatcher() (config.Watcher, error) {
// Next will be blocked until the Stop method is called // Next will be blocked until the Stop method is called
func (w *watcher) Next() ([]*config.KeyValue, error) { func (w *watcher) Next() ([]*config.KeyValue, error) {
select { <-w.ctx.Done()
case <-w.ctx.Done():
return nil, w.ctx.Err() return nil, w.ctx.Err()
} }
}
func (w *watcher) Stop() error { func (w *watcher) Stop() error {
w.cancel() w.cancel()

Loading…
Cancel
Save