File tree 3 files changed +3
-10
lines changed
3 files changed +3
-10
lines changed Original file line number Diff line number Diff line change @@ -21,13 +21,6 @@ Layout/LineContinuationSpacing:
21
21
Exclude :
22
22
- ' lib/zip/bzip2/errors.rb'
23
23
24
- # Offense count: 3
25
- # This cop supports unsafe autocorrection (--autocorrect-all).
26
- Performance/UnfreezeString :
27
- Exclude :
28
- - ' lib/zip/bzip2/decompress.rb'
29
- - ' lib/zip/bzip2/decompressor.rb'
30
-
31
24
# Offense count: 9
32
25
# This cop supports safe autocorrection (--autocorrect).
33
26
Style/FileRead :
Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ def initialize(options = {})
18
18
end
19
19
20
20
def decompress ( data )
21
- result = '' . dup
21
+ result = + ''
22
22
23
23
with_input_buffer ( data ) do |input_buffer |
24
24
@libbz2 . input_buffer = input_buffer
Original file line number Diff line number Diff line change @@ -8,11 +8,11 @@ class Decompressor < ::Zip::Decompressor #:nodoc:
8
8
def initialize ( *args )
9
9
super
10
10
11
- @buffer = '' . dup
11
+ @buffer = + ''
12
12
@bzip2_ffi_decompressor = ::Zip ::Bzip2 ::Decompress . new
13
13
end
14
14
15
- def read ( length = nil , outbuf = '' . dup )
15
+ def read ( length = nil , outbuf = + '' )
16
16
return return_value_on_eof ( length ) if eof
17
17
18
18
fill_buffer ( length )
You can’t perform that action at this time.
0 commit comments