Bases: BaseModel
Default list type for owners, chiefs, members
Source code in structs/teams.py
| class TeamUsers(BaseModel):
''' Default list type for owners, chiefs, members '''
owners: list[str] = Field(default_factory=list,
description="list of owners' uids")
chiefs: list[str] = Field(default_factory=list,
description="list of chiefs' uids")
members: list[str] = Field(
default_factory=list, description="list of members' uids")
@validator('*', pre=True)
def process_none(cls, value: list[str] | None) -> list[str]: # pylint: disable=no-self-argument
''' process none '''
if value is None:
return []
return value
|
process_none
process_none(value: list[str] | None) -> list[str]
process none
Source code in structs/teams.py
| @validator('*', pre=True)
def process_none(cls, value: list[str] | None) -> list[str]: # pylint: disable=no-self-argument
''' process none '''
if value is None:
return []
return value
|