audit: use start_with? to check the name in the desc

This commit is contained in:
Baptiste Fontaine 2016-02-02 14:42:45 +01:00
parent 5b89c33cac
commit cdd990f9d7

View File

@ -411,7 +411,7 @@ class FormulaAuditor
problem "Description shouldn't start with an indefinite article (#{$1})"
end
if desc =~ /^#{formula.name}\s/i
if desc.downcase.start_with? "#{formula.name} "
problem "Description shouldn't include the formula name"
end
end