Fix more 'Lint/ShadowingOuterLocalVar' warnings reported by ameba

This commit is contained in:
Samantaz Fox
2022-01-20 17:17:22 +01:00
parent 1c91110464
commit 12b818a83c
10 changed files with 22 additions and 18 deletions

View File

@@ -98,7 +98,7 @@ module Invidious::Routes::API::Manifest
height = fmt["height"].as_i
# Resolutions reported by YouTube player (may not accurately reflect source)
height = potential_heights.min_by { |i| (height - i).abs }
height = potential_heights.min_by { |x| (height - x).abs }
next if unique_res && heights.includes? height
heights << height