Skip to content

Commit

Permalink
Prefer 'apply', which more implements the partial.
Browse files Browse the repository at this point in the history
  • Loading branch information
jaraco committed Sep 22, 2022
1 parent 4913c48 commit b30e67c
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions jaraco/docker.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
import functools
import pathlib

from jaraco.functools import compose
from jaraco.functools import apply
from jaraco.context import suppress


@functools.partial(compose, bool)
@apply(bool)
@suppress(FileNotFoundError)
def text_in_file(text, filename):
return any(text in line for line in filename.open())
Expand Down

0 comments on commit b30e67c

Please sign in to comment.