Skip to content

Commit 95b1027

Browse files
committed
rewrite switch as if
1 parent 1f816a9 commit 95b1027

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

internal/watcher/credentials/credential_watcher_service.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -146,8 +146,7 @@ func (cws *CredentialWatcherService) handleEvent(ctx context.Context, event fsno
146146

147147
slog.DebugContext(ctx, "Processing FSNotify event", "event", event)
148148

149-
switch {
150-
case event.Has(fsnotify.Rename):
149+
if event.Has(fsnotify.Rename) {
151150
if !slices.Contains(cws.watcher.WatchList(), event.Name) {
152151
cws.filesBeingWatched.Store(event.Name, false)
153152
}

0 commit comments

Comments
 (0)