Fix Style/VerboseBlock issues

This commit is contained in:
syeopite
2021-09-24 19:42:43 -07:00
parent 35d15c7c2b
commit e91421253e
15 changed files with 44 additions and 44 deletions

View File

@@ -173,7 +173,7 @@ module Kemal
return
end
if @cached_files.sum { |element| element[1][:data].bytesize } + (size = File.size(file_path)) < CACHE_LIMIT
if @cached_files.sum(&.[1].[:data].bytesize) + (size = File.size(file_path)) < CACHE_LIMIT
data = Bytes.new(size)
File.open(file_path) do |file|
file.read(data)