In retrospective, when would nil ever enter the equation at all?

This commit is contained in:
Karl Southern 2015-11-06 15:01:02 +00:00
parent dd29d16a31
commit 1487b41b3e

View File

@ -122,11 +122,7 @@ class LogStash::Outputs::Jdbc < LogStash::Outputs::Base
when false when false
statement.setBoolean(idx + 1, false) statement.setBoolean(idx + 1, false)
else else
if event[i].nil? and i =~ /%{/ statement.setString(idx + 1, event.sprintf(i))
statement.setString(idx + 1, event.sprintf(i))
else
statement.setString(idx + 1, nil)
end
end end
end end