mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-31 07:20:13 +00:00
Clean up unneeded break in switch
There's no need to explicitly add break after every case, as switch statements will break automatically.
This commit is contained in:
parent
23111ad414
commit
7cef40cb83
@ -396,7 +396,6 @@ func (a *APIInstaller) registerResourceHandlers(path string, storage rest.Storag
|
||||
actions = appendIf(actions, action{"WATCH", "watch/" + itemPath, nameParams, namer, false}, isWatcher)
|
||||
actions = appendIf(actions, action{"CONNECT", itemPath, nameParams, namer, false}, isConnecter)
|
||||
actions = appendIf(actions, action{"CONNECT", itemPath + "/{path:*}", proxyParams, namer, false}, isConnecter && connectSubpath)
|
||||
break
|
||||
default:
|
||||
namespaceParamName := "namespaces"
|
||||
// Handler for standard REST verbs (GET, PUT, POST and DELETE).
|
||||
@ -450,7 +449,6 @@ func (a *APIInstaller) registerResourceHandlers(path string, storage rest.Storag
|
||||
actions = appendIf(actions, action{"LIST", resource, params, namer, true}, isLister)
|
||||
actions = appendIf(actions, action{"WATCHLIST", "watch/" + resource, params, namer, true}, allowWatchList)
|
||||
}
|
||||
break
|
||||
}
|
||||
|
||||
// Create Routes for the actions.
|
||||
|
Loading…
Reference in New Issue
Block a user