Skip to content

Commit d2e98dd

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 0d2d02f commit d2e98dd

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

src/_pytask/collect.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -247,11 +247,7 @@ def _is_filtered_object(obj: Any) -> bool:
247247
# Filter objects overwriting the ``__getattr__`` method like :class:`pytask.mark` or
248248
# ``from ibis import _``.
249249
attr_name = "attr_that_definitely_does_not_exist"
250-
if hasattr(obj, attr_name) and not bool(
251-
inspect.getattr_static(obj, attr_name, False)
252-
):
253-
return True
254-
return False
250+
return bool(hasattr(obj, attr_name) and not bool(inspect.getattr_static(obj, attr_name, False)))
255251

256252

257253
@hookimpl

0 commit comments

Comments
 (0)