Skip to content

Commit 422584d

Browse files
committed
Allow passing None to categories (tags) when uploading files.
1 parent 9b0ed65 commit 422584d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

dvuploader/file.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ class File(BaseModel):
1818
description (str): The description of the file.
1919
directory_label (str): The label of the directory where the file is stored.
2020
mimeType (str): The MIME type of the file.
21-
categories (List[str]): The categories associated with the file.
21+
categories (Optional[List[str]]): The categories associated with the file.
2222
restrict (bool): Indicates if the file is restricted.
2323
checksum_type (ChecksumTypes): The type of checksum used for the file.
2424
storageIdentifier (Optional[str]): The identifier of the storage where the file is stored.
@@ -46,7 +46,7 @@ class File(BaseModel):
4646
description: str = ""
4747
directory_label: str = Field(default="", alias="directoryLabel")
4848
mimeType: str = "application/octet-stream"
49-
categories: List[str] = ["DATA"]
49+
categories: Optional[List[str]] = ["DATA"]
5050
restrict: bool = False
5151
checksum_type: ChecksumTypes = Field(default=ChecksumTypes.MD5, exclude=True)
5252
storageIdentifier: Optional[str] = None

0 commit comments

Comments
 (0)