Skip to content

Commit

Permalink
Use Sequence type for Collection user lists
Browse files Browse the repository at this point in the history
  • Loading branch information
bencap committed Jan 27, 2025
1 parent 7642328 commit 2b9acf3
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions src/mavedb/view_models/collection.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
from datetime import date
from typing import Any
from typing import Any, Sequence

from pydantic import Field
from pydantic.types import Optional
Expand Down Expand Up @@ -77,9 +77,9 @@ class SavedCollection(CollectionBase):
experiment_urns: list[str]
score_set_urns: list[str]

admins: list[SavedUser]
viewers: list[SavedUser]
editors: list[SavedUser]
admins: Sequence[SavedUser]
viewers: Sequence[SavedUser]
editors: Sequence[SavedUser]

creation_date: date
modification_date: date
Expand All @@ -97,9 +97,9 @@ class Collection(SavedCollection):
created_by: Optional[User]
modified_by: Optional[User]

admins: list[User]
viewers: list[User]
editors: list[User]
admins: Sequence[User]
viewers: Sequence[User]
editors: Sequence[User]


# Properties to return to admin clients or non-admin clients who are admins of the returned collection
Expand Down

0 comments on commit 2b9acf3

Please sign in to comment.