Fixed conditional in Zip::File.open_buffer()
It required it to be be both an IO _and_ a String, which isn't exactly possible.
This commit is contained in:
parent
652916025a
commit
9f6bc1e2e9
|
@ -116,7 +116,7 @@ module Zip
|
|||
# (This can be used to extract data from a
|
||||
# downloaded zip archive without first saving it to disk.)
|
||||
def open_buffer(io)
|
||||
unless io.is_a?(IO) && io.is_a?(String)
|
||||
unless io.is_a?(IO) || io.is_a?(String)
|
||||
raise "Zip::ZipFile.open_buffer expects an argument of class String or IO. Found: #{io.class}"
|
||||
end
|
||||
zf = ::Zip::File.new('', true, true)
|
||||
|
|
Loading…
Reference in New Issue