1
0
mirror of https://github.com/imgproxy/imgproxy.git synced 2025-01-23 11:14:48 +02:00

Check presets after vips init

This commit is contained in:
DarthSim 2019-11-11 17:54:46 +06:00
parent 4467960b95
commit 1383bf2788
2 changed files with 5 additions and 4 deletions

View File

@ -458,10 +458,6 @@ func configure() {
conf.GCSEnabled = true
}
if err := checkPresets(conf.Presets); err != nil {
logFatal(err.Error())
}
if conf.WatermarkOpacity <= 0 {
logFatal("Watermark opacity should be greater than 0")
} else if conf.WatermarkOpacity > 1 {

View File

@ -24,6 +24,11 @@ func initialize() {
initDownloading()
initErrorsReporting()
initVips()
if err := checkPresets(conf.Presets); err != nil {
shutdownVips()
logFatal(err.Error())
}
}
func main() {