Not showing multiple file error bug (#450)

When user selects the following, Danger can't show the multiple file error:
- [ ] Changed more than one extension, but all changes are related
This commit is contained in:
Lucas Farah 2017-08-31 14:29:44 -03:00 committed by GitHub
parent dfcedbe274
commit 86a7e9b4f8
1 changed files with 1 additions and 1 deletions

View File

@ -18,7 +18,7 @@ if git.commits.any? { |c| c.message =~ /^Merge branch '#{github.branch_for_base}
end
# Restrict changing only one extension per PR
if git.modified_files.grep(/^Sources\//).count > 1
if (git.modified_files.grep(/^Sources\//).count > 1) && (github.pr_body.include? "- [ ] Changed more than one extension, but all changes are related")
fail("Please, modify only one extension per pull request.")
end