Skip to content

Commit 93f894a

Browse files
committed
type
1 parent f4126f3 commit 93f894a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/models-library/src/models_library/projects_nodes.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"""
44

55
from enum import auto
6-
from typing import Annotated, Any, TypeAlias, Union
6+
from typing import Annotated, Any, Self, TypeAlias, Union
77

88
from common_library.basic_types import DEFAULT_FACTORY
99
from pydantic import (
@@ -104,7 +104,7 @@ class NodeShareState(BaseModel):
104104
] = None
105105

106106
@model_validator(mode="after")
107-
def _validate_lock_state(self) -> "NodeShareState":
107+
def _validate_lock_state(self) -> Self:
108108
if self.locked and (self.current_user_groupids is None or self.status is None):
109109
msg = "If the node is locked, both 'current_user_groupids' and 'status' must be set"
110110
raise ValueError(msg)

0 commit comments

Comments
 (0)