add token check for file download operation.

This commit is contained in:
Yoshihiro OKUMURA 2024-07-08 18:07:26 +09:00
parent c2a67aa861
commit 0d8deb02d7
Signed by: orrisroot
GPG Key ID: 470AA444C92904B2

View File

@ -111,6 +111,7 @@ class FilesApi(BaseApi):
def download(self, file: File, path: str) -> bool:
# print(self.__class__.__name__ + "::" + sys._getframe().f_code.co_name)
url = file.download_url
token_check(self.connection)
response = self.connection.get(url, stream=True)
self._raise_response_error(response)
try: