diff --git a/CONTRIBUTORS.txt b/CONTRIBUTORS.txt index e57d3b0..b30a438 100644 --- a/CONTRIBUTORS.txt +++ b/CONTRIBUTORS.txt @@ -3,4 +3,5 @@ Project created by Tarek Ziadé. Contributors: - Tamás Gulácsi +- Nicolas Dumazet diff --git a/flake8/run.py b/flake8/run.py index 68682bd..222a800 100644 --- a/flake8/run.py +++ b/flake8/run.py @@ -70,11 +70,9 @@ def hg_hook(ui, repo, **kwargs): for file_ in _get_files(repo, **kwargs): warnings += check_file(file_) - strict = ui.config('flake8', 'strict') - if strict is None: - strict = True + strict = ui.configbool('flake8', 'strict', default=True) - if strict.lower() in ('1', 'true'): + if strict: return warnings return 0