mirror of
https://github.com/PyCQA/flake8.git
synced 2026-04-02 03:46:53 +00:00
Fixes --exit-zero when empty --diff
fixes pycqa/flake8/merge_requests!137
This commit is contained in:
parent
15de413f9e
commit
cc037338df
2 changed files with 7 additions and 18 deletions
|
|
@ -124,7 +124,9 @@ class Application(object):
|
|||
if self.options.count:
|
||||
print(self.result_count)
|
||||
|
||||
if not self.options.exit_zero:
|
||||
if self.options.exit_zero:
|
||||
raise SystemExit(self.catastrophic_failure)
|
||||
else:
|
||||
raise SystemExit(
|
||||
(self.result_count > 0) or self.catastrophic_failure
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue