summaryrefslogtreecommitdiff
path: root/cmd
diff options
context:
space:
mode:
authorNick White <git@njw.name>2022-03-21 18:43:10 +0000
committerNick White <git@njw.name>2022-03-21 18:43:10 +0000
commit34b1354179d41a27035968dd20fdd2da4ac35765 (patch)
tree36ce151c3c27d589e4d6d93bb457ae288f65a339 /cmd
parent61f66b3382822f3c9d5891e5c0641e8a37ec8804 (diff)
rescribe: Improve error messages if no pages are found
Diffstat (limited to 'cmd')
-rw-r--r--cmd/rescribe/main.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/cmd/rescribe/main.go b/cmd/rescribe/main.go
index 67ae8a7..a743ef2 100644
--- a/cmd/rescribe/main.go
+++ b/cmd/rescribe/main.go
@@ -622,12 +622,12 @@ func uploadbook(ctx context.Context, dir string, name string, conn Pipeliner, no
func downloadbook(dir string, name string, conn Pipeliner) error {
err := pipeline.DownloadBestPages(dir, name, conn)
if err != nil {
- return fmt.Errorf("Error downloading best pages: %v", err)
+ return fmt.Errorf("No images found")
}
- err1 := pipeline.DownloadBestPngs(dir, name, conn)
- if err1 != nil {
- return fmt.Errorf("Error downloading best pngs: %v", err)
+ err = pipeline.DownloadBestPngs(dir, name, conn)
+ if err != nil {
+ return fmt.Errorf("No images found")
}
err = pipeline.DownloadPdfs(dir, name, conn)