Skip to content

Commit

Permalink
Switched libcst._nodes.statement imports to cst. imports
Browse files Browse the repository at this point in the history
  • Loading branch information
surge119 committed Jun 5, 2024
1 parent fb27778 commit 7368528
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions src/fixit/rules/deprecated_abc_import.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,6 @@
import libcst as cst

import libcst.matchers as m
from libcst._nodes.statement import (
BaseCompoundStatement,
ImportFrom,
SimpleStatementLine,
)

from fixit import Invalid, LintRule, Valid

Expand Down Expand Up @@ -147,8 +142,8 @@ def visit_ImportFrom(self, node: cst.ImportFrom) -> None:
)

def get_import_from(
self, node: Union[SimpleStatementLine, BaseCompoundStatement]
) -> Optional[ImportFrom]:
self, node: Union[cst.SimpleStatementLine, cst.BaseCompoundStatement]
) -> Optional[cst.ImportFrom]:
"""
Iterate over a Statement Sequence and return a Statement if it is a
`cst.ImportFrom` statement.
Expand Down

0 comments on commit 7368528

Please sign in to comment.