Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Mark Byrne <31762852+mbyrnepr2@users.noreply.github.com>
  • Loading branch information
clavedeluna and mbyrnepr2 committed Nov 25, 2022
1 parent 676a4bb commit d483c83
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions pylint/checkers/logging.py
Original file line number Diff line number Diff line change
Expand Up @@ -403,7 +403,7 @@ def _count_supplied_tokens(args: list[nodes.NodeNG]) -> int:
return sum(1 for arg in args if not isinstance(arg, nodes.Keyword))


def str_formatting_in_f_string(node: nodes.NodeNG) -> bool:
def str_formatting_in_f_string(node: nodes.JoinedStr) -> bool:
"""Determine whether the node represents an f-string with string formatting.
For example: `f'Hello %s'`
Expand All @@ -416,6 +416,5 @@ def str_formatting_in_f_string(node: nodes.NodeNG) -> bool:
)


# Detect % formatting inside an f-string, such as `f'Hello %s'`
def register(linter: PyLinter) -> None:
linter.register_checker(LoggingChecker(linter))

0 comments on commit d483c83

Please sign in to comment.