summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--pkg/commands.go2
-rw-r--r--pkg/files.go2
-rw-r--r--pkg/packages.go2
-rw-r--r--pkg/services.go4
4 files changed, 5 insertions, 5 deletions
diff --git a/pkg/commands.go b/pkg/commands.go
index df42919..5403e5f 100644
--- a/pkg/commands.go
+++ b/pkg/commands.go
@@ -42,7 +42,7 @@ type CommandPromise struct {
}
func (c *CommandPromise) IfRepaired(p ...Promise) Promise {
- c.chain = p
+ c.chain = append(c.chain, p...)
return c
}
diff --git a/pkg/files.go b/pkg/files.go
index 366bacc..eb3fa38 100644
--- a/pkg/files.go
+++ b/pkg/files.go
@@ -64,7 +64,7 @@ func (f *FilePromise) Template(contents any) *FilePromise {
// We want to satisfy the Promise interface
func (f *FilePromise) IfRepaired(p ...Promise) Promise {
- f.chain = p
+ f.chain = append(f.chain, p...)
return f
}
diff --git a/pkg/packages.go b/pkg/packages.go
index 20d3e3d..75346eb 100644
--- a/pkg/packages.go
+++ b/pkg/packages.go
@@ -39,7 +39,7 @@ type PackagePromise struct {
}
func (p *PackagePromise) IfRepaired(ps ...Promise) Promise {
- p.chain = ps
+ p.chain = append(p.chain, ps...)
return p
}
diff --git a/pkg/services.go b/pkg/services.go
index 658cd0e..7e4f114 100644
--- a/pkg/services.go
+++ b/pkg/services.go
@@ -41,8 +41,8 @@ type ServicePromise struct {
status Status
}
-func (s *ServicePromise) IfRepaired(ps ...Promise) Promise {
- s.chain = ps
+func (s *ServicePromise) IfRepaired(p ...Promise) Promise {
+ s.chain = append(s.chain, p...)
return s
}