summaryrefslogtreecommitdiff
path: root/libpod/options.go
diff options
context:
space:
mode:
Diffstat (limited to 'libpod/options.go')
-rw-r--r--libpod/options.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/libpod/options.go b/libpod/options.go
index e6751d68d..1a29c0705 100644
--- a/libpod/options.go
+++ b/libpod/options.go
@@ -181,7 +181,7 @@ func WithStaticDir(dir string) RuntimeOption {
// WithHooksDir sets the directory to look for OCI runtime hooks config.
// Note we are not saving this in database, since this is really just for used
// for testing.
-func WithHooksDir(hooksDir string, dirNotExistFatal bool) RuntimeOption {
+func WithHooksDir(hooksDir string) RuntimeOption {
return func(rt *Runtime) error {
if rt.valid {
return ErrRuntimeFinalized
@@ -191,8 +191,8 @@ func WithHooksDir(hooksDir string, dirNotExistFatal bool) RuntimeOption {
return errors.Wrap(ErrInvalidArg, "empty-string hook directories are not supported")
}
- rt.config.HooksDir = hooksDir
- rt.config.HooksDirNotExistFatal = dirNotExistFatal
+ rt.config.HooksDir = []string{hooksDir}
+ rt.config.HooksDirNotExistFatal = true
return nil
}
}