Skip to content

Commit a9c212f

Browse files
committed
lint: clear range
1 parent 70b3529 commit a9c212f

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

lib/psf/php_serial.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ def self.unserialize!(data = '')
118118
end
119119
extract_until!(data, '}')
120120
# if keys are sequential numbers, return array
121-
value = value.values if (Array(0..value.length - 1) == value.keys) && !value.empty?
121+
value = value.values if (Array(0..(value.length - 1)) == value.keys) && !value.empty?
122122
when 'O'
123123
value = {}
124124
length = extract_until!(data, ':').to_i

lib/psf/string_utils.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ def byteslice!(start_index, length = nil)
1313
byte_length = bytesize - byte_start_index if byte_start_index + byte_length > bytesize
1414

1515
out = byteslice(byte_start_index, byte_length)
16-
replace(byteslice(0, byte_start_index) + byteslice(byte_start_index + byte_length..-1))
16+
replace(byteslice(0, byte_start_index) + byteslice((byte_start_index + byte_length)..-1))
1717
out
1818
end
1919
end

0 commit comments

Comments
 (0)