From 1ec981b1fb823c82ebf20971bba1a324f87374f1 Mon Sep 17 00:00:00 2001 From: Nova Kwok Date: Fri, 29 Dec 2023 21:24:56 +0800 Subject: [PATCH] Read all pages (#308) * Read all pages * Bump to 0.10.6 --- config/config.go | 2 +- encoder/encoder.go | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/config/config.go b/config/config.go index 50c875c6c..59d5bd037 100644 --- a/config/config.go +++ b/config/config.go @@ -46,7 +46,7 @@ var ( ProxyMode bool Prefetch bool Config = NewWebPConfig() - Version = "0.10.5" + Version = "0.10.6" WriteLock = cache.New(5*time.Minute, 10*time.Minute) ConvertLock = cache.New(5*time.Minute, 10*time.Minute) RemoteRaw = "./remote-raw" diff --git a/encoder/encoder.go b/encoder/encoder.go index c4b77b301..b3cd2fd54 100644 --- a/encoder/encoder.go +++ b/encoder/encoder.go @@ -111,6 +111,7 @@ func convertImage(rawPath, optimizedPath, imageType string, extraParams config.E // Image is only opened here img, err := vips.LoadImageFromFile(rawPath, &vips.ImportParams{ FailOnError: boolFalse, + NumPages: intMinusOne, }) defer img.Close()