summaryrefslogtreecommitdiff
path: root/internal/pipeline
diff options
context:
space:
mode:
Diffstat (limited to 'internal/pipeline')
-rw-r--r--internal/pipeline/put.go6
1 files changed, 6 insertions, 0 deletions
diff --git a/internal/pipeline/put.go b/internal/pipeline/put.go
index 68ad70e..aba9e0e 100644
--- a/internal/pipeline/put.go
+++ b/internal/pipeline/put.go
@@ -51,6 +51,7 @@ func CheckImages(ctx context.Context, dir string) error {
close(checker)
}()
+ n := 0
for path := range checker {
select {
case <-ctx.Done():
@@ -70,6 +71,11 @@ func CheckImages(ctx context.Context, dir string) error {
if err != nil {
return fmt.Errorf("Decoding image %s failed: %v", path, err)
}
+ n++
+ }
+
+ if n == 0 {
+ return fmt.Errorf("No images found")
}
return nil