rubocop: Use include? rather than match
This commit is contained in:
parent
00075c228c
commit
8461cf24f1
@ -180,7 +180,7 @@ module RuboCop
|
|||||||
end
|
end
|
||||||
|
|
||||||
[:mac?, :linux?].each do |method_name|
|
[:mac?, :linux?].each do |method_name|
|
||||||
next if formula_tap != "homebrew-core" || file_path&.match(/linuxbrew/)
|
next if formula_tap != "homebrew-core" || file_path&.include?("linuxbrew")
|
||||||
|
|
||||||
find_instance_method_call(body_node, "OS", method_name) do |check|
|
find_instance_method_call(body_node, "OS", method_name) do |check|
|
||||||
problem "Don't use #{check.source}; Homebrew/core only supports macOS"
|
problem "Don't use #{check.source}; Homebrew/core only supports macOS"
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user