Closed lisa closed 6 years ago
I think the main intent was reducing amount of warning messages in Ruby 2.4. Thank you for describing the issue accurately. I'm pretty sure we could replace the defined?
with @content ||=
and it should work fine as well. Are you able to submit a proper PR to fix it?
@qoobaa Hi, I opened #126 which should address this.
It appears that fc4d193 introduced a change that has initialized
@content
inS3::Object#initialize
. By doing thisif defined?(@content)
returns true, thus returning anil
object.I made a short test to isolate and verify the issue. Small test and output over various Ruby versions can be located in a gist.
Unfortunately I'm not sure what the intent is behind fc4d193 so I'm not really able to submit a PR for this.