Fix handling bool in sql input plugin (#9540)
This commit is contained in:
parent
837eb31b3f
commit
ecf27ab956
|
|
@ -191,6 +191,8 @@ func ToBool(value interface{}) (bool, error) {
|
||||||
return v > 0, nil
|
return v > 0, nil
|
||||||
case float64:
|
case float64:
|
||||||
return v > 0, nil
|
return v > 0, nil
|
||||||
|
case bool:
|
||||||
|
return v, nil
|
||||||
case nil:
|
case nil:
|
||||||
return false, nil
|
return false, nil
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue