aboutsummaryrefslogtreecommitdiffhomepage
path: root/internal/pkg/pkg.go
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2026-01-09 05:31:38 +0900
committerOphestra <cat@gensokyo.uk>2026-01-09 05:31:38 +0900
commit34cb4ebd3bc1d7aaa263929c7ae27ac46298b285 (patch)
tree707ad22a4bbd6201c60206ec9451d56625b76939 /internal/pkg/pkg.go
parentf7124667145d1f7c614d9fc644bc07bb6174454a (diff)
internal/pkg: pass context to file cure
This removes the left over embedded contexts. Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'internal/pkg/pkg.go')
-rw-r--r--internal/pkg/pkg.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/internal/pkg/pkg.go b/internal/pkg/pkg.go
index 199a6177..362e4121 100644
--- a/internal/pkg/pkg.go
+++ b/internal/pkg/pkg.go
@@ -265,7 +265,7 @@ type File interface {
// Callers must not modify the returned byte slice.
//
// Result must remain identical across multiple invocations.
- Cure() ([]byte, error)
+ Cure(ctx context.Context) ([]byte, error)
Artifact
}
@@ -726,7 +726,7 @@ func (c *Cache) openFile(f File) (r io.ReadCloser, err error) {
return
}
var data []byte
- if data, err = f.Cure(); err != nil {
+ if data, err = f.Cure(c.ctx); err != nil {
return
}
r = io.NopCloser(bytes.NewReader(data))
@@ -931,7 +931,7 @@ func (c *Cache) Cure(a Artifact) (
}
var data []byte
- data, err = f.Cure()
+ data, err = f.Cure(c.ctx)
if err != nil {
return
}