Merge pull request #2725 from MikeMcQuaid/audit-formulae-options-fix

audit: fix false negative for formulae options.
This commit is contained in:
Mike McQuaid 2017-06-03 10:01:10 +01:00 committed by GitHub
commit d6c4dfc783

View File

@ -959,6 +959,7 @@ class FormulaAuditor
if line =~ /depends_on\s+['"](.+)['"]\s+=>\s+(.*)/
dep = $1
$2.split(" ").map do |o|
break if ["if", "unless"].include?(o)
next unless o =~ /^\[?['"](.*)['"]/
problem "Dependency #{dep} should not use option #{$1}"
end