summaryrefslogtreecommitdiff
path: root/flake8
diff options
context:
space:
mode:
authorIan Cordasco <graffatcolmingov@gmail.com>2016-03-11 21:08:41 -0600
committerIan Cordasco <graffatcolmingov@gmail.com>2016-03-11 21:08:41 -0600
commit4c797c9ff7300b39601943e841d98dcb3cb691e3 (patch)
tree3792d641b01a78fa681c0f799905e3f369e21c8e /flake8
parentd331558868e7262948d169d322f044117eb871fd (diff)
downloadflake8-4c797c9ff7300b39601943e841d98dcb3cb691e3.tar.gz
Simplify how we check if a file is excluded
Our typical usage always passes is_path_excluded which checks the basename and the full path
Diffstat (limited to 'flake8')
-rw-r--r--flake8/utils.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/flake8/utils.py b/flake8/utils.py
index 7e08e41..1ceb76f 100644
--- a/flake8/utils.py
+++ b/flake8/utils.py
@@ -117,7 +117,7 @@ def filenames_from(arg, predicate=None):
for root, sub_directories, files in os.walk(arg):
for filename in files:
joined = os.path.join(root, filename)
- if predicate(filename) or predicate(joined):
+ if predicate(joined):
continue
yield joined
# NOTE(sigmavirus24): os.walk() will skip a directory if you