Fix compatibility to ruby-3.2

... which is the default ruby version on Github Actions.
This commit is contained in:
Lars Kanis
2026-01-18 22:55:12 +01:00
committed by Benoit Daloze
parent 708024e6c9
commit 5fcbc91943
+1 -1
View File
@@ -21,7 +21,7 @@ WINDOWS_TOOLCHAIN_VERSIONS_URLS_REGEXPS = [
# Validate all the URLs in the versions json # Validate all the URLs in the versions json
def validate(versions, allowed_urls_regexps) def validate(versions, allowed_urls_regexps)
versions.values.flat_map(&:values).each do |url| versions.values.flat_map(&:values).each do |url|
if allowed_urls_regexps.none? { |regexp| regexp.match? url } if allowed_urls_regexps.none? { |regexp| regexp.match? url.to_s }
raise SecurityError, "Unexpected URL: #{url}" raise SecurityError, "Unexpected URL: #{url}"
end end
end end