mirror of
https://github.com/imgproxy/imgproxy.git
synced 2025-03-17 20:17:48 +02:00
Proper arguments check for strip_metadata
This commit is contained in:
parent
bc10a053ed
commit
a1679e5e09
@ -851,10 +851,12 @@ func applyFilenameOption(po *processingOptions, args []string) error {
|
||||
}
|
||||
|
||||
func applyStripMetadataOption(po *processingOptions, args []string) error {
|
||||
if len(args[0]) > 0 {
|
||||
po.StripMetadata = parseBoolOption(args[0])
|
||||
if len(args) > 1 {
|
||||
return fmt.Errorf("Invalid strip metadata arguments: %v", args)
|
||||
}
|
||||
|
||||
po.StripMetadata = parseBoolOption(args[0])
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user