mirror of https://bitbucket.org/ausocean/av.git
Merged in break-bad-sat-or-bright (pull request #268)
revid/revid.go: break if the given saturation or brightness vars are invalid
This commit is contained in:
commit
8edfbeb369
|
@ -433,12 +433,14 @@ func (r *Revid) Update(vars map[string]string) error {
|
|||
s, err := strconv.ParseInt(value, 10, 0)
|
||||
if err != nil {
|
||||
r.config.Logger.Log(logger.Warning, pkg+"invalid saturation param", "value", value)
|
||||
break
|
||||
}
|
||||
r.config.Saturation = int(s)
|
||||
case "Brightness":
|
||||
b, err := strconv.ParseUint(value, 10, 0)
|
||||
if err != nil {
|
||||
r.config.Logger.Log(logger.Warning, pkg+"invalid brightness param", "value", value)
|
||||
break
|
||||
}
|
||||
r.config.Brightness = uint(b)
|
||||
case "Exposure":
|
||||
|
|
Loading…
Reference in New Issue