mirror of
https://github.com/stashapp/stash.git
synced 2025-12-17 04:14:39 +03:00
Add anonymise database task (#3186)
This commit is contained in:
12
pkg/utils/func.go
Normal file
12
pkg/utils/func.go
Normal file
@@ -0,0 +1,12 @@
|
||||
package utils
|
||||
|
||||
// Do executes each function in the slice in order. If any function returns an error, it is returned immediately.
|
||||
func Do(fn []func() error) error {
|
||||
for _, f := range fn {
|
||||
if err := f(); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
Reference in New Issue
Block a user