mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-06 22:47:29 -06:00
Boyscouting modern python typing
CURA-8555
This commit is contained in:
parent
a7fcc15197
commit
f67d086182
2 changed files with 5 additions and 5 deletions
|
@ -39,8 +39,8 @@ class DFFileUploader:
|
|||
:param on_error: The method to be called when an error occurs.
|
||||
"""
|
||||
|
||||
self._http = http # type: HttpRequestManager
|
||||
self._df_file = df_file # type: Union[DFLibraryFileUploadResponse, DFPrintJobUploadResponse]
|
||||
self._http: HttpRequestManager = http
|
||||
self._df_file: Union[DFLibraryFileUploadResponse, DFPrintJobUploadResponse] = df_file
|
||||
self._file_name = ""
|
||||
if isinstance(self._df_file, DFLibraryFileUploadResponse):
|
||||
self._file_name = self._df_file.file_name
|
||||
|
@ -51,7 +51,7 @@ class DFFileUploader:
|
|||
self._file_name = ""
|
||||
else:
|
||||
raise TypeError("Incorrect input type")
|
||||
self._data = data # type: bytes
|
||||
self._data: bytes = data
|
||||
|
||||
self._on_finished = on_finished
|
||||
self._on_success = on_success
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue