utils: brew style --fix.

This commit is contained in:
Mike McQuaid 2020-05-21 10:15:34 +01:00
parent 223762915f
commit e33dc9e916
No known key found for this signature in database
GPG Key ID: 48A898132FD8EE70

View File

@ -437,13 +437,13 @@ module Kernel
n_back_bytes = max_bytes_in - n_front_bytes
if n_front_bytes.zero?
front = bytes[1..0]
back = bytes[-max_bytes_in..-1]
back = bytes[-max_bytes_in..]
elsif n_back_bytes.zero?
front = bytes[0..(max_bytes_in - 1)]
back = bytes[1..0]
else
front = bytes[0..(n_front_bytes - 1)]
back = bytes[-n_back_bytes..-1]
back = bytes[-n_back_bytes..]
end
out = front + glue_bytes + back
out.force_encoding("UTF-8")