Skip to content

Commit

Permalink
Fix Style/Next cop.
Browse files Browse the repository at this point in the history
  • Loading branch information
hainesr committed Sep 25, 2019
1 parent 237c04b commit b614336
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions lib/zip/entry.rb
Original file line number Diff line number Diff line change
Expand Up @@ -615,13 +615,13 @@ def create_file(dest_path, _continue_on_exists_proc = proc { Zip.continue_on_exi
while (buf = is.sysread(::Zip::Decompressor::CHUNK_SIZE, buf))
os << buf
bytes_written += buf.bytesize
if bytes_written > size && !warned
message = "Entry #{name} should be #{size}B but is larger when inflated"
raise ::Zip::EntrySizeError, message if ::Zip.validate_entry_sizes
next unless bytes_written > size && !warned

puts "WARNING: #{message}"
warned = true
end
message = "Entry #{name} should be #{size}B but is larger when inflated"
raise ::Zip::EntrySizeError, message if ::Zip.validate_entry_sizes

puts "WARNING: #{message}"
warned = true
end
end
end
Expand Down

0 comments on commit b614336

Please sign in to comment.