mirror of
https://github.com/go-micro/go-micro.git
synced 2025-06-18 22:17:44 +02:00
improve code quality (#2128)
* Fix inefficient string comparison * Fix unnecessary calls to Printf * Canonicalize header key * Replace `t.Sub(time.Now())` with `time.Until` * Remove unnecessary blank (_) identifier * Remove unnecessary use of slice * Remove unnecessary comparison with bool
This commit is contained in:
committed by
GitHub
parent
0f0ace1a44
commit
26b859c4f9
@ -41,7 +41,7 @@ func (w *watcher) Next() (*source.ChangeSet, error) {
|
||||
|
||||
// try get the event
|
||||
select {
|
||||
case event, _ := <-w.fw.Events:
|
||||
case event := <-w.fw.Events:
|
||||
if event.Op == fsnotify.Rename {
|
||||
// check existence of file, and add watch again
|
||||
_, err := os.Stat(event.Name)
|
||||
|
Reference in New Issue
Block a user