-
-
Save anonymous/82fb4158315cbc2dcfc6 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Code: | |
puts "#start" | |
puts type_name | |
puts record.has_key?("_type") | |
type_name = record[:_type] if record.has_key?("_type") | |
puts type_name | |
puts "#end" | |
Log: | |
#start | |
fluentd | |
true | |
#end | |
Why type_name set to nil ? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Code:
p "#start"
p type_name
p record.has_key?("_type")
type_name = record["_type"] if record.has_key?("_type")
p type_name
p "#end"
Logs:
"#start"
"fluentd"
false
nil
"#end"