mirror of
https://github.com/k3s-io/k3s.git
synced 2024-06-07 19:41:36 +00:00
13 lines
184 B
Go
13 lines
184 B
Go
|
package common
|
||
|
|
||
|
func Seq(fns []func() error) func() error {
|
||
|
return func() error {
|
||
|
for _, fn := range fns {
|
||
|
if err := fn(); err != nil {
|
||
|
return err
|
||
|
}
|
||
|
}
|
||
|
return nil
|
||
|
}
|
||
|
}
|