fix imports and styles after refactor
This commit is contained in:
@ -1,5 +1,5 @@
|
||||
from _weakref import proxy
|
||||
from typing import List, Type, Optional, Union, Tuple
|
||||
from typing import List, Optional, TYPE_CHECKING, Tuple, Type, Union
|
||||
from weakref import proxy
|
||||
|
||||
import ormar
|
||||
from ormar.exceptions import RelationshipInstanceError
|
||||
@ -8,6 +8,9 @@ from ormar.fields.many_to_many import ManyToManyField
|
||||
from ormar.relations import Relation
|
||||
from ormar.relations.relation import RelationType
|
||||
|
||||
if TYPE_CHECKING: # pragma no cover
|
||||
from ormar import Model
|
||||
|
||||
|
||||
class RelationsManager:
|
||||
def __init__(
|
||||
@ -125,4 +128,4 @@ class RelationsManager:
|
||||
if name in item._orm:
|
||||
relation_name = item.resolve_relation_name(related_model, item)
|
||||
item._orm.remove(name, related_model)
|
||||
related_model._orm.remove(relation_name, item)
|
||||
related_model._orm.remove(relation_name, item)
|
||||
|
||||
Reference in New Issue
Block a user