mirror of
https://git.nadeko.net/Fijxu/invidious.git
synced 2026-03-01 11:50:17 +00:00
Fix more 'Lint/ShadowingOuterLocalVar' warnings reported by ameba
This commit is contained in:
@@ -175,9 +175,9 @@ module Kemal
|
||||
|
||||
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)
|
||||
end
|
||||
|
||||
File.open(file_path) { |f| f.read(data) }
|
||||
|
||||
filestat = File.info(file_path)
|
||||
|
||||
@cached_files[file_path] = {data: data, filestat: filestat}
|
||||
|
||||
Reference in New Issue
Block a user