Skip to content

Commit 10bb40a

Browse files
committed
revert models groups.py and pagination.py
1 parent fa084e9 commit 10bb40a

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

services/api-server/src/simcore_service_api_server/models/domain/groups.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@
44
class UsersGroup(BaseModel):
55
gid: str
66
label: str
7-
description: str = None # TODO: should be nullable
7+
description: str | None = None
88

99

1010
class Groups(BaseModel):
1111
me: UsersGroup
12-
organizations: list[UsersGroup] = [] # TODO: should be nullable
12+
organizations: list[UsersGroup] | None = []
1313
all_: UsersGroup = Field(..., alias="all")

services/api-server/src/simcore_service_api_server/models/pagination.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,9 +56,7 @@ class OnePage(BaseModel, Generic[T]):
5656
"""
5757

5858
items: Sequence[T]
59-
total: NonNegativeInt = Field(
60-
default=None, validate_default=True
61-
) # TODO: should be nullable
59+
total: NonNegativeInt | None = Field(default=None, validate_default=True)
6260

6361
@field_validator("total", mode="before")
6462
@classmethod

0 commit comments

Comments
 (0)